@font-face {
  font-family: "Vazirmatn";
  src: url("/static/fonts/Vazirmatn-wght.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --ink: #16211f;
  --muted: #5d6b68;
  --line: #dfe6e3;
  --bg: #ffffff;
  --soft: #f3f7f5;
  --brand: #0f5c4d;
  --brand-dark: #0a4439;
  --brand-soft: #e2f1ec;
  --warn: #a8500a;
  --warn-soft: #fdeedc;
  --blue: #1d4f91;
  --blue-soft: #e4eefb;
  --danger: #b3261e;
  --radius: 12px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-size: 16px;
  line-height: 1.9;
  color: var(--ink);
  background: var(--bg);
}
h1, h2, h3, p, ul, dl, dd, figure, fieldset { margin: 0; padding: 0; }
ul { list-style: none; }
fieldset { border: 0; min-width: 0; }
a { color: inherit; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 640px; }

/* header */
.top { position: sticky; top: 0; z-index: 5; background: rgba(255, 255, 255, .95); border-bottom: 1px solid var(--line); }
.top-in { display: flex; align-items: center; justify-content: space-between; height: 56px; }
.brand { font-weight: 800; font-size: 18px; color: var(--brand); }

/* buttons */
.btn {
  display: inline-block;
  padding: 12px 22px;
  border: 0;
  border-radius: 10px;
  background: var(--brand);
  color: #fff;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
.btn:hover { background: var(--brand-dark); }
.btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid #7cc4b3; outline-offset: 2px; }
.btn[disabled] { opacity: .6; cursor: default; }
.btn-small { padding: 6px 16px; font-size: 14px; }
.btn-block { display: block; width: 100%; padding: 14px; font-size: 17px; }

/* hero */
.hero { padding: 40px 0 44px; background: linear-gradient(180deg, var(--brand-soft), #fff); }
.eyebrow { color: var(--brand); font-weight: 700; font-size: 14px; margin-bottom: 8px; }
h1 { font-size: 28px; line-height: 1.55; font-weight: 800; max-width: 760px; }
.lead { margin: 16px 0 24px; max-width: 640px; color: #33423f; font-size: 17px; }
.note { margin-top: 12px; font-size: 13px; color: var(--muted); }

/* sections */
.section { padding: 44px 0; }
.alt { background: var(--soft); }
h2 { font-size: 23px; font-weight: 800; line-height: 1.6; margin-bottom: 20px; }
h3 { font-size: 17px; font-weight: 700; }
.sub { margin: -12px 0 24px; color: var(--muted); font-size: 15px; }

.grid3, .grid4 { display: grid; gap: 14px; }
.card, .feature { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.card p, .feature p { color: #44534f; font-size: 15px; margin-top: 6px; }
.num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; margin-bottom: 8px;
  border-radius: 50%; background: var(--warn-soft); color: var(--warn); font-weight: 800;
}
.feature { border-top: 3px solid var(--brand); }

/* mockups */
.mocks { display: grid; gap: 28px; }
.mock figcaption { font-weight: 700; margin-bottom: 10px; }
.screen {
  background: #fff;
  border: 1px solid #cfd9d5;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(15, 60, 50, .08);
  overflow: hidden;
  font-size: 14px;
  line-height: 1.8;
}
.bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 14px; background: var(--brand); color: #fff; }
.bar.center { justify-content: center; }
.pill { padding: 1px 10px; border-radius: 99px; background: rgba(255, 255, 255, .18); font-size: 12px; white-space: nowrap; }
.tabs { display: flex; gap: 6px; padding: 10px 14px; overflow-x: auto; border-bottom: 1px solid var(--line); }
.tabs span { padding: 2px 12px; border-radius: 99px; background: var(--soft); color: var(--muted); font-size: 13px; white-space: nowrap; }
.tabs .on { background: var(--brand-soft); color: var(--brand); font-weight: 700; }

.rows li { display: flex; justify-content: space-between; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.rows li:last-child { border-bottom: 0; }
.rows b { display: block; font-weight: 700; }
.rows small { display: block; color: var(--muted); font-size: 12.5px; }
.rows .end { text-align: left; flex-shrink: 0; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.rows .end b { font-size: 13px; }
.tag { display: inline-block; padding: 0 9px; border-radius: 6px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.tag.sale { background: var(--blue-soft); color: var(--blue); }
.tag.rent { background: var(--brand-soft); color: var(--brand); }
.tag.match { background: var(--brand-soft); color: var(--brand); }
.tag.near { background: var(--warn-soft); color: var(--warn); }
.rows small.ok { color: var(--brand); }
.rows small.warn { color: var(--warn); font-weight: 700; }
.act { display: inline-block; padding: 1px 10px; border: 1px solid var(--brand); border-radius: 6px; color: var(--brand); font-size: 12px; font-weight: 700; white-space: nowrap; }

.req { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; padding: 14px; background: var(--soft); border-bottom: 1px solid var(--line); }
.req dt { color: var(--muted); font-size: 12px; }
.req dd { font-weight: 700; font-size: 13.5px; }
.found { padding: 10px 14px 0; font-weight: 700; color: var(--brand); }

.phone .screen { max-width: 340px; border-radius: 26px; border-width: 6px; border-color: #24332f; }
.hello { padding: 16px 16px 4px; font-size: 15px; }
.visits { padding: 8px 12px 14px; display: grid; gap: 10px; }
.visits li { border: 1px solid var(--line); border-radius: 10px; padding: 12px; }
.visits time { display: block; color: var(--brand); font-weight: 800; }
.visits b { display: block; }
.visits small { display: block; color: var(--muted); font-size: 12.5px; }
.choices { display: flex; gap: 8px; margin-top: 10px; }
.choices span { flex: 1; text-align: center; padding: 5px; border: 1px solid var(--line); border-radius: 8px; font-size: 13px; font-weight: 700; color: var(--muted); }
.choices .yes { background: var(--brand); border-color: var(--brand); color: #fff; }

/* form */
form { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.field { margin-bottom: 16px; }
.two { display: grid; gap: 0 14px; }
label, legend { display: block; font-weight: 700; font-size: 15px; margin-bottom: 4px; }
.opt { font-weight: 400; color: var(--muted); font-size: 13px; }
input[type="text"], input[type="tel"], select, textarea {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid #c3cfcb;
  border-radius: 9px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 16px;
}
input[dir="ltr"] { text-align: left; }
input[dir="ltr"]::placeholder { text-align: left; }
textarea { resize: vertical; line-height: 1.8; }
.bad { border-color: var(--danger) !important; }
.err { color: var(--danger); font-size: 13px; min-height: 0; }
.radios { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.radios label { display: flex; align-items: center; gap: 8px; margin: 0; padding: 9px 12px; border: 1px solid #c3cfcb; border-radius: 9px; font-weight: 500; cursor: pointer; }
.radios input { accent-color: var(--brand); width: 18px; height: 18px; margin: 0; }
.radios label:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.form-msg { color: var(--danger); font-size: 14px; margin-bottom: 8px; }
.form-msg:empty { display: none; }
.done { background: var(--brand-soft); border: 1px solid #b5dccf; border-radius: var(--radius); padding: 28px 18px; text-align: center; }
.done h3 { font-size: 20px; color: var(--brand); }
[hidden] { display: none !important; }

/* stepped flow: contact, five questions, optional agency details */
.flow { background: #fff; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; scroll-margin-top: 68px; box-shadow: 0 8px 24px rgba(15, 60, 50, .06); }
.fl-pad { padding: 20px 16px; }
.fl-top { display: flex; align-items: center; justify-content: space-between; min-height: 44px; padding: 4px 8px 0 16px; font-size: 13px; color: var(--muted); }
.fl-back { min-height: 44px; padding: 0 10px; border: 0; background: none; color: var(--brand); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.fl-back[hidden] + .fl-count { margin-right: 10px; }
.fl-bar { height: 4px; margin: 0 16px; border-radius: 4px; background: var(--brand-soft); overflow: hidden; }
.fl-bar i { display: block; height: 100%; width: 0; border-radius: 4px; background: var(--brand); transition: width .25s ease; }
.fl-body { padding: 18px 16px 20px; min-height: 340px; }
.fl-body h3 { font-size: 18px; line-height: 1.85; margin-bottom: 14px; outline: 0; }
.fl-hint { margin: -8px 0 14px; font-size: 13.5px; color: var(--muted); }
.fl-saved { display: inline-block; margin-bottom: 10px; padding: 1px 10px; border-radius: 99px; background: var(--brand-soft); color: var(--brand); font-size: 13px; font-weight: 700; }
.flow input[type="text"], .flow input[type="tel"] { min-height: 52px; font-size: 17px; }
.flow .btn { display: block; width: 100%; min-height: 54px; margin-top: 16px; font-size: 17px; }
.flow button { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
.opts { display: grid; gap: 10px; }
.opt {
  display: flex; align-items: center; gap: 12px;
  width: 100%; min-height: 56px; padding: 10px 14px;
  border: 1.5px solid #c3cfcb; border-radius: 12px; background: #fff;
  color: var(--ink); font: inherit; font-size: 16px; font-weight: 500; text-align: right; cursor: pointer;
  transition: background .12s, border-color .12s;
}
.opt::before { content: ""; flex-shrink: 0; width: 20px; height: 20px; border: 2px solid #9fb0ab; border-radius: 50%; }
.opt.multi::before { border-radius: 6px; }
.opt[aria-pressed="true"] { border-color: var(--brand); background: var(--brand-soft); font-weight: 700; }
.opt[aria-pressed="true"]::before { border-color: var(--brand); background: var(--brand); box-shadow: inset 0 0 0 3px #fff; }
.opt:disabled { opacity: .45; cursor: default; }
.opt:active:not(:disabled) { background: var(--brand-soft); }
.fl-text { margin-top: 12px; }
.fl-quit { display: block; min-height: 44px; margin: 10px auto 0; padding: 0 12px; border: 0; background: none; color: var(--muted); font: inherit; font-size: 13.5px; text-decoration: underline; cursor: pointer; }
.fl-done { text-align: center; padding-top: 36px; }
.fl-done h3 { font-size: 21px; color: var(--brand); }
.fl-check { display: flex; align-items: center; justify-content: center; width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); font-size: 32px; font-weight: 800; }
@media (prefers-reduced-motion: reduce) { .fl-bar i, .opt { transition: none; } html { scroll-behavior: auto; } }

/* standalone questionnaire page (/q) */
.solo { min-height: 100vh; min-height: 100dvh; background: var(--soft); padding: 20px 0 32px; font-size: 17px; }
.solo .brand { font-size: 15px; margin-bottom: 6px; }
.solo h1 { font-size: 24px; line-height: 1.6; }
.solo-lead { margin: 8px 0 18px; color: #33423f; }
.solo .fl-body h3 { font-size: 19px; }
.solo .opt { font-size: 17px; }
.solo-foot { margin-top: 18px; text-align: center; font-size: 14px; }
.solo-foot a { color: var(--brand); }
@media (min-width: 720px) { .solo { padding-top: 56px; } .solo h1 { font-size: 30px; } }

.foot { padding: 22px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; text-align: center; }

@media (min-width: 720px) {
  h1 { font-size: 40px; }
  .hero { padding: 72px 0; }
  .section { padding: 64px 0; }
  h2 { font-size: 28px; }
  .grid3 { grid-template-columns: repeat(3, 1fr); }
  .grid4 { grid-template-columns: repeat(2, 1fr); }
  .two { grid-template-columns: 1fr 1fr; }
  .radios { grid-template-columns: repeat(4, 1fr); }
  form { padding: 28px; }
  .mocks { grid-template-columns: 1fr 1fr; align-items: start; }
  .mock.phone { grid-column: 1 / -1; justify-self: center; text-align: center; }
  .mock.phone .screen { text-align: right; margin: 0 auto; }
}
@media (min-width: 1000px) {
  .grid4 { grid-template-columns: repeat(4, 1fr); }
}
