:root {
  --adam-red: #aa2419;
  --adam-red-dark: #8c1d14;
  --ink: #1c1c1e;
  --muted: #6b6b70;
  --line: #e8e8ea;
  --soft: #faf7f5;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Segoe UI", Tahoma, "Noto Kufi Arabic", Arial, sans-serif;
  background: var(--soft);
  color: var(--ink);
  line-height: 1.7;
}
.wrap { max-width: 860px; margin: 0 auto; padding: 0 18px 64px; }
.topbar {
  background: var(--adam-red);
  color: #fff;
  padding: 14px 0;
}
.topbar .wrap { padding-bottom: 0; display: flex; align-items: center; gap: 12px; }
.brand { font-weight: 700; font-size: 20px; }
.brand small { display: block; font-weight: 400; font-size: 12px; opacity: .85; }
.logo-dot {
  width: 34px; height: 34px; border-radius: 50%;
  background: #fff; color: var(--adam-red);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 17px; flex: none;
}
nav.site-nav {
  background: #fff; border-bottom: 1px solid var(--line);
  padding: 8px 0; margin-bottom: 24px;
}
nav.site-nav .wrap { padding-bottom: 0; display: flex; gap: 16px; flex-wrap: wrap; }
nav.site-nav a { color: var(--muted); text-decoration: none; font-size: 14px; padding: 4px 2px; }
nav.site-nav a.active, nav.site-nav a:hover { color: var(--adam-red); border-bottom: 2px solid var(--adam-red); }
h1 { font-size: 26px; margin: 18px 0 6px; }
h2 { font-size: 20px; margin: 34px 0 10px; color: var(--adam-red-dark); }
p.lead { color: var(--muted); margin: 0 0 8px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 18px 20px; margin: 14px 0;
}
.module {
  display: block; text-decoration: none; color: inherit;
  border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 16px; margin: 10px 0; background: #fff;
}
.module.ready { border-right: 4px solid var(--adam-red); }
.module.ready:hover { background: #fdf3f4; }
.module.soon { opacity: .65; }
.module .m-name { font-weight: 700; }
.module .m-detail { font-size: 13px; color: var(--muted); }
.badge {
  display: inline-block; font-size: 11px; border-radius: 999px;
  padding: 2px 10px; margin-inline-start: 8px;
  background: #fdecea; color: var(--adam-red); font-weight: 700;
}
.badge.gray { background: #eee; color: var(--muted); }
.badge.green { background: #e8f6ec; color: #146c2e; }
ul.points li { margin: 8px 0; }
.note { font-size: 13px; color: var(--muted); border-top: 1px dashed var(--line); padding-top: 10px; margin-top: 12px; }
.video-slot {
  border: 2px dashed var(--line); border-radius: 14px; background: #fff;
  padding: 34px 20px; text-align: center; color: var(--muted);
}
.video-slot .play {
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--adam-red); color: #fff; font-size: 22px;
  display: inline-flex; align-items: center; justify-content: center; margin-bottom: 10px;
}
.q-block { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; margin: 12px 0; background: #fff; }
.q-title { font-weight: 700; margin-bottom: 8px; }
.q-opt {
  display: block; width: 100%; text-align: right; font: inherit;
  border: 1px solid var(--line); border-radius: 10px; background: var(--soft);
  padding: 10px 14px; margin: 6px 0; cursor: pointer;
}
.q-opt:hover { border-color: var(--adam-red); }
.q-opt.selected { background: var(--adam-red); color: #fff; border-color: var(--adam-red); }
.result-box {
  border-radius: 12px; padding: 14px 16px; margin: 14px 0; font-weight: 700;
}
.result-box.ok { background: #e8f6ec; color: #146c2e; }
.result-box.warn { background: #fff4e5; color: #8a4b00; }
.chat-box { border: 1px solid var(--line); border-radius: 14px; background: #fff; overflow: hidden; }
.chat-log { padding: 16px; min-height: 120px; }
.msg { max-width: 85%; border-radius: 14px; padding: 10px 14px; margin: 8px 0; white-space: pre-wrap; }
.msg.customer { background: #f0f0f2; margin-inline-start: 0; }
.msg.me { background: var(--adam-red); color: #fff; margin-inline-start: auto; }
.msg.system { background: #fff4e5; color: #8a4b00; max-width: 100%; font-size: 14px; }
.chat-input { display: flex; gap: 8px; border-top: 1px solid var(--line); padding: 10px; }
.chat-input textarea {
  flex: 1; font: inherit; resize: none; border: 1px solid var(--line);
  border-radius: 10px; padding: 10px 12px; min-height: 46px;
}
.btn {
  font: inherit; font-weight: 700; border: none; border-radius: 10px;
  background: var(--adam-red); color: #fff; padding: 10px 18px; cursor: pointer;
  text-decoration: none; display: inline-block;
}
.btn:hover { background: var(--adam-red-dark); }
.btn.secondary { background: #fff; color: var(--adam-red); border: 1px solid var(--adam-red); }
.rubric { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; margin: 12px 0; }
.rubric li { margin: 6px 0; }
.self-check { display: flex; gap: 8px; align-items: flex-start; }
.self-check input { margin-top: 6px; }
footer { margin-top: 40px; font-size: 12px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 14px; }
.form-field { margin: 12px 0; }
.form-field label { display: block; font-weight: 700; font-size: 14px; margin-bottom: 4px; }
.form-field input {
  width: 100%; font: inherit; border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 12px; background: #fff;
}
.form-error { background: #fdecea; color: var(--adam-red); border-radius: 10px; padding: 10px 14px; margin: 10px 0; font-size: 14px; display: none; }
.hero { text-align: center; padding: 28px 0 8px; }
.hero h1 { font-size: 30px; }
.user-chip { margin-inline-start: auto; font-size: 13px; color: #fff; font-weight: 700; background: rgba(255,255,255,.2); padding: 4px 14px; border-radius: 999px; }

.brand-logo { width: 40px; height: 40px; border-radius: 50%; flex: none; box-shadow: 0 1px 4px rgba(0,0,0,.25); }
.card, .module, .q-block, .chat-box { box-shadow: 0 1px 3px rgba(28,28,30,.06); }
.hero .brand-hero-logo { width: 96px; height: 96px; border-radius: 50%; box-shadow: 0 4px 14px rgba(170,36,25,.25); margin-bottom: 14px; }

.tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 20px 0 14px; position: sticky; top: 0; background: var(--soft); padding: 10px 0; z-index: 5; }
.tabs button { font: inherit; font-weight: 700; border: 1px solid var(--line); background: #fff; color: var(--muted); border-radius: 999px; padding: 8px 18px; cursor: pointer; }
.tabs button.active { background: var(--adam-red); border-color: var(--adam-red); color: #fff; }
.tab-section { display: none; }
.tab-section.active { display: block; }
