/* Everything is served from this server: no Google Fonts, no CDN. A visitor in
   Iran must not wait on a host that is filtered there. */
@font-face { font-family: Vazirmatn; src: url(fonts/Vazirmatn-Regular.woff2) format("woff2"), url(fonts/Vazirmatn-Regular.ttf) format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: Vazirmatn; src: url(fonts/Vazirmatn-Medium.woff2) format("woff2"), url(fonts/Vazirmatn-Medium.ttf) format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: Vazirmatn; src: url(fonts/Vazirmatn-Bold.woff2) format("woff2"), url(fonts/Vazirmatn-Bold.ttf) format("truetype"); font-weight: 700; font-display: swap; }

:root {
  --bg: #f4f5fa;
  --bg-grad-1: #dfe7ff;
  --bg-grad-2: #e3f6ef;
  --bg-grad-3: #fbe9f0;
  --card: rgba(255,255,255,.72);
  --card-solid: #ffffff;
  --line: rgba(60,60,67,.12);
  --text: #1c1c1e;
  --muted: #6c6c72;
  --blue: #007aff;
  --purple: #5e5ce6;
  --green: #34c759;
  --red: #ff3b30;
  --orange: #ff9500;
  --shadow: 0 10px 30px rgba(30,40,80,.08);
  --radius: 22px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d0d10;
    --bg-grad-1: #1a1d33;
    --bg-grad-2: #0f2621;
    --bg-grad-3: #2a1621;
    --card: rgba(36,36,40,.72);
    --card-solid: #1c1c1e;
    --line: rgba(235,235,245,.12);
    --text: #f2f2f7;
    --muted: #a1a1a8;
    --blue: #0a84ff;
    --purple: #7d7aff;
    --green: #30d158;
    --red: #ff453a;
    --orange: #ff9f0a;
    --shadow: 0 10px 30px rgba(0,0,0,.35);
  }
}
:root[data-theme="dark"] {
  --bg: #0d0d10; --bg-grad-1: #1a1d33; --bg-grad-2: #0f2621; --bg-grad-3: #2a1621;
  --card: rgba(36,36,40,.72); --card-solid: #1c1c1e; --line: rgba(235,235,245,.12);
  --text: #f2f2f7; --muted: #a1a1a8; --blue: #0a84ff; --purple: #7d7aff;
  --green: #30d158; --red: #ff453a; --orange: #ff9f0a; --shadow: 0 10px 30px rgba(0,0,0,.35);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Vazirmatn, Tahoma, sans-serif;
  color: var(--text);
  background: var(--bg);
  background-image:
    radial-gradient(60rem 40rem at 90% -10%, var(--bg-grad-1), transparent 60%),
    radial-gradient(50rem 40rem at -10% 30%, var(--bg-grad-2), transparent 60%),
    radial-gradient(50rem 40rem at 80% 90%, var(--bg-grad-3), transparent 60%);
  background-attachment: fixed;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--blue); text-decoration: none; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }

/* icons: the SVG is a mask so it takes the text colour in both themes */
.ic { display: inline-block; width: 1.2em; height: 1.2em; background: currentColor;
      -webkit-mask: var(--i) center / contain no-repeat; mask: var(--i) center / contain no-repeat;
      vertical-align: -0.2em; flex: none; }

/* header */
header { position: sticky; top: 0; z-index: 10; backdrop-filter: saturate(180%) blur(18px);
         -webkit-backdrop-filter: saturate(180%) blur(18px);
         background: color-mix(in srgb, var(--bg) 70%, transparent); border-bottom: 1px solid var(--line); }
.bar { display: flex; align-items: center; gap: 16px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--text); }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
nav { margin-inline-start: auto; display: flex; gap: 22px; font-size: 15px; }
nav a { color: var(--muted); }
nav a:hover { color: var(--text); }
.btn { display: inline-flex; align-items: center; gap: 8px; border-radius: 999px; padding: 10px 20px;
       font: inherit; font-weight: 700; border: 0; cursor: pointer; white-space: nowrap; }
.btn-primary { background: var(--blue); color: #fff; box-shadow: 0 6px 18px color-mix(in srgb, var(--blue) 35%, transparent); }
.btn-primary:hover { filter: brightness(1.07); }
.btn-ghost { background: var(--card); color: var(--text); border: 1px solid var(--line); }
.bar .btn { padding: 8px 16px; font-size: 14px; }

/* hero */
.hero { display: grid; grid-template-columns: 1fr 1.15fr; gap: 48px; align-items: center; padding: 72px 0 56px; }
.pill { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500;
        background: var(--card); border: 1px solid var(--line); padding: 4px 12px; border-radius: 999px; color: var(--muted); }
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
h1 { font-size: clamp(30px, 4.4vw, 46px); line-height: 1.35; margin: 18px 0 14px; letter-spacing: -.5px; }
h1 em { font-style: normal; background: linear-gradient(90deg, var(--blue), var(--purple));
        -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: 18px; color: var(--muted); margin: 0 0 28px; }
.cta { display: flex; gap: 12px; flex-wrap: wrap; }
.cta .btn { padding: 13px 26px; font-size: 16px; }
.small { font-size: 13px; color: var(--muted); margin-top: 14px; }

/* the app mockup: drawn in HTML, sample levels only, no results claimed */
.mock { background: var(--card); border: 1px solid var(--line); border-radius: 26px; box-shadow: var(--shadow);
        backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); padding: 18px; }
.mock-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.mock-top b { font-size: 18px; margin-inline-end: auto; }
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; padding: 3px 10px; border-radius: 999px;
        background: var(--card-solid); border: 1px solid var(--line); }
.chip i { width: 7px; height: 7px; border-radius: 50%; background: var(--green); display: inline-block; }
.mode { display: flex; align-items: center; gap: 10px; background: var(--card-solid); border: 1px solid var(--line);
        border-radius: 14px; padding: 10px 14px; margin-bottom: 14px; font-size: 14px; }
.mode .ic { color: var(--blue); }
.mode .sw { margin-inline-start: auto; width: 44px; height: 26px; border-radius: 999px; background: var(--line); position: relative; }
.mode .sw::after { content: ""; position: absolute; top: 3px; right: 3px; width: 20px; height: 20px; border-radius: 50%;
                   background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.rows { background: var(--card-solid); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; }
.row + .row { border-top: 1px solid var(--line); }
.sq { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: #fff; flex: none; }
.sq.sell { background: var(--red); } .sq.buy { background: var(--green); } .sq.mgmt { background: var(--purple); }
.row .t { font-weight: 700; font-size: 15px; }
.row .s { font-size: 12px; color: var(--muted); direction: rtl; }
.row > div { min-width: 0; flex: 1; }
.row .tag { margin-inline-start: auto; font-size: 11px; padding: 2px 10px; border-radius: 999px; white-space: nowrap; }
.tag.watch { background: color-mix(in srgb, var(--orange) 16%, transparent); color: var(--orange); }
.tag.placed { background: color-mix(in srgb, var(--blue) 14%, transparent); color: var(--blue); }
.mock-cap { font-size: 12px; color: var(--muted); text-align: center; margin: 10px 0 0; }

/* sections */
section { padding: 56px 0; scroll-margin-top: 64px; }
h2 { font-size: clamp(24px, 3vw, 32px); margin: 0 0 8px; }
.sub { color: var(--muted); margin: 0 0 32px; font-size: 17px; }
.grid { display: grid; gap: 16px; }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g2 { grid-template-columns: repeat(2, 1fr); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px;
        box-shadow: var(--shadow); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.card h3 { margin: 12px 0 6px; font-size: 18px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }
.badge { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; color: #fff; font-size: 20px; }
.b-blue { background: var(--blue); } .b-purple { background: var(--purple); } .b-green { background: var(--green); }
.b-orange { background: var(--orange); } .b-red { background: var(--red); } .b-gray { background: #8e8e93; }
.step-n { font-size: 13px; font-weight: 700; color: var(--blue); }

.req { list-style: none; padding: 0; margin: 0; }
.req li { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.req li:last-child { border-bottom: 0; }
.req .ic { color: var(--green); margin-top: 6px; }
.req.no .ic { color: var(--muted); }

.price { text-align: center; padding: 34px 22px; }
.price .big { font-size: 22px; font-weight: 700; margin: 6px 0; }

details { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 4px 20px; }
details + details { margin-top: 10px; }
summary { cursor: pointer; font-weight: 700; padding: 14px 0; list-style: none; display: flex; align-items: center; gap: 10px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; margin-inline-start: auto; color: var(--muted); font-size: 22px; font-weight: 400; }
details[open] summary::after { content: "−"; }
details p { margin: 0 0 16px; color: var(--muted); }

.risk { border-color: color-mix(in srgb, var(--orange) 45%, var(--line)); }
.risk h2 { display: flex; align-items: center; gap: 10px; font-size: 22px; }
.risk h2 .ic { color: var(--orange); }
.risk p { color: var(--muted); margin: 8px 0 0; }

footer { border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }
footer .sp { margin-inline-start: auto; }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding-top: 40px; gap: 32px; }
  .g3 { grid-template-columns: 1fr 1fr; }
  nav { display: none; }
  .bar .btn { margin-inline-start: auto; }
}
@media (max-width: 600px) {
  .g3, .g2 { grid-template-columns: 1fr; }
  .lead { font-size: 16px; }
  .row { flex-wrap: wrap; }
  .row > div { flex-basis: calc(100% - 46px); }
  .row .tag { margin-inline-start: 46px; }
  section { padding: 40px 0; }
}

/* shared additions: the plans grid, the order page */
.g4 { grid-template-columns: repeat(4, 1fr); }
.mono { font-family: Consolas, "Courier New", monospace; direction: ltr; word-break: break-all; }
.narrow { max-width: 640px; margin: 0 auto; }
.form { display: grid; gap: 14px; }
.form label { font-weight: 500; font-size: 15px; }
.input { width: 100%; font: inherit; color: var(--text); background: var(--card-solid); border: 1px solid var(--line);
         border-radius: 12px; padding: 10px 14px; }
.input:focus { outline: 2px solid color-mix(in srgb, var(--blue) 45%, transparent); border-color: transparent; }
.input.ltr { direction: ltr; text-align: left; }
.opts { display: grid; gap: 10px; }
.opt { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 14px; cursor: pointer;
       background: var(--card-solid); border: 1px solid var(--line); }
.opt input { accent-color: var(--blue); width: 18px; height: 18px; }
.opt .p { margin-inline-start: auto; font-weight: 700; }
.kv { display: grid; grid-template-columns: auto 1fr auto; gap: 10px 14px; align-items: center; }
.kv .k { color: var(--muted); font-size: 14px; }
.kv .v { font-weight: 700; }
.note { padding: 12px 16px; border-radius: 14px; font-size: 14px; }
.note.ok { background: color-mix(in srgb, var(--green) 14%, transparent); }
.note.warn { background: color-mix(in srgb, var(--orange) 16%, transparent); }
.note.err { background: color-mix(in srgb, var(--red) 14%, transparent); }
.keybox { font-size: 22px; font-weight: 700; text-align: center; padding: 18px; border-radius: 16px;
          background: var(--card-solid); border: 2px dashed var(--green); }
.btn-sm { padding: 6px 14px; font-size: 13px; }
@media (max-width: 1000px) { .g4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .g4 { grid-template-columns: 1fr; } .kv { grid-template-columns: 1fr auto; } .kv .k { grid-column: 1 / -1; } }
#plans { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.price .amt { font-size: 20px; font-weight: 700; color: var(--blue); margin-bottom: 4px; }
[hidden] { display: none !important; }
.kv .mono { text-align: right; }
