/* ZanAI.tech — design system
   Чистый CSS, без сборки. Профессиональный legal-tech стиль. */

:root {
  /* Brand */
  --navy-900: #0b1220;
  --navy-800: #111a2e;
  --navy-700: #18233d;
  --indigo-600: #4f46e5;
  --indigo-500: #6366f1;
  --indigo-400: #818cf8;
  --emerald-500: #10b981;
  --emerald-400: #34d399;
  --amber-500: #f59e0b;
  --rose-500: #f43f5e;

  /* Neutrals */
  --bg: #f6f7fb;
  --surface: #ffffff;
  --surface-2: #f9fafb;
  --border: #e6e8ef;
  --border-strong: #d3d7e3;
  --text: #0f172a;
  --text-2: #475569;
  --text-3: #94a3b8;

  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06), 0 1px 3px rgba(15, 23, 42, .05);
  --shadow: 0 4px 16px rgba(15, 23, 42, .08);
  --shadow-lg: 0 20px 50px rgba(15, 23, 42, .15);

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 600;
  font-size: 15px;
  line-height: 1;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .12s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: linear-gradient(135deg, var(--indigo-600), var(--indigo-500));
  color: #fff;
  box-shadow: 0 6px 18px rgba(79, 70, 229, .28);
}
.btn-primary:hover { box-shadow: 0 10px 26px rgba(79, 70, 229, .38); }
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border-strong);
}
.btn-ghost:hover { background: var(--surface-2); border-color: var(--text-3); }
.btn-light {
  background: rgba(255,255,255,.12);
  color: #fff;
  border-color: rgba(255,255,255,.22);
}
.btn-light:hover { background: rgba(255,255,255,.2); }
.btn-block { width: 100%; }
.btn-lg { padding: 15px 26px; font-size: 16px; }
.btn-sm { padding: 9px 14px; font-size: 13px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(246, 247, 251, .82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -.02em;
}
.brand-mark {
  width: 34px; height: 34px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--indigo-600), var(--indigo-400));
  display: grid; place-items: center;
  color: #fff; font-weight: 800; font-size: 18px;
  box-shadow: 0 4px 12px rgba(79,70,229,.35);
}
.brand-mark.sm { width: 28px; height: 28px; font-size: 15px; border-radius: 8px; }
.brand .tld { color: var(--indigo-500); }
.nav {
  display: flex;
  align-items: center;
  gap: 30px;
}
.nav-links { display: flex; gap: 28px; }
.nav-links a {
  font-size: 15px;
  color: var(--text-2);
  font-weight: 500;
  transition: color .15s;
}
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: 12px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(900px 400px at 80% -10%, rgba(99,102,241,.18), transparent 60%),
    radial-gradient(700px 380px at 5% 10%, rgba(16,185,129,.12), transparent 55%);
  padding: 80px 0 70px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 56px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--indigo-600);
  background: rgba(99,102,241,.1);
  border: 1px solid rgba(99,102,241,.2);
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 22px;
}
.hero h1 {
  font-size: 52px;
  line-height: 1.07;
  letter-spacing: -.03em;
  font-weight: 800;
  margin-bottom: 22px;
}
.hero h1 .grad {
  background: linear-gradient(120deg, var(--indigo-600), var(--emerald-500));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero p.lead {
  font-size: 19px;
  color: var(--text-2);
  max-width: 540px;
  margin-bottom: 32px;
}
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 26px; }
.hero-trust { display: flex; gap: 24px; flex-wrap: wrap; color: var(--text-3); font-size: 14px; }
.hero-trust span { display: inline-flex; align-items: center; gap: 7px; }

/* Hero visual: mock dashboard card */
.hero-visual {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 18px;
  transform: perspective(1200px) rotateY(-7deg) rotateX(2deg);
}
.mock-bar { display: flex; gap: 6px; margin-bottom: 14px; }
.mock-bar i { width: 11px; height: 11px; border-radius: 50%; background: var(--border-strong); }
.mock-bar i:nth-child(1){ background:#ff5f57;} .mock-bar i:nth-child(2){ background:#febc2e;} .mock-bar i:nth-child(3){ background:#28c840;}
.mock-doc {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px;
  background: var(--surface-2);
}
.mock-doc h4 { font-size: 14px; margin-bottom: 12px; display:flex; justify-content:space-between; align-items:center;}
.risk-row { display: flex; align-items: center; justify-content: space-between; padding: 9px 0; border-bottom: 1px dashed var(--border); font-size: 13px; }
.risk-row:last-child { border-bottom: 0; }
.pill { font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.pill.high { color: #b91c1c; background: #fee2e2; }
.pill.mid { color: #b45309; background: #fef3c7; }
.pill.low { color: #047857; background: #d1fae5; }

/* ---------- Sections ---------- */
.section { padding: 76px 0; }
.section.alt { background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 48px; }
.section-head .eyebrow { margin-bottom: 14px; }
.section-head h2 { font-size: 38px; letter-spacing: -.025em; font-weight: 800; margin-bottom: 14px; }
.section-head p { font-size: 18px; color: var(--text-2); }

/* Features */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.feature {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform .15s ease, box-shadow .2s ease, border-color .2s;
}
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--border-strong); }
.feature .ic {
  width: 46px; height: 46px;
  border-radius: 12px;
  display: grid; place-items: center;
  font-size: 22px;
  margin-bottom: 16px;
  background: rgba(99,102,241,.1);
}
.feature h3 { font-size: 18px; margin-bottom: 8px; letter-spacing: -.01em; }
.feature p { font-size: 15px; color: var(--text-2); }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: step; }
.step { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px 22px; position: relative; }
.step .num {
  width: 38px; height: 38px; border-radius: 10px;
  background: var(--navy-900); color: #fff;
  display: grid; place-items: center; font-weight: 700; margin-bottom: 16px;
}
.step h3 { font-size: 17px; margin-bottom: 8px; }
.step p { font-size: 14px; color: var(--text-2); }

/* Pricing */
.pricing-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; align-items: stretch; }
.plan {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  display: flex; flex-direction: column;
  position: relative;
  transition: transform .15s, box-shadow .2s, border-color .2s;
}
.plan:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.plan.popular { border-color: var(--indigo-500); box-shadow: 0 14px 40px rgba(79,70,229,.18); }
.plan.popular::before {
  content: "Популярный";
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--indigo-600); color: #fff;
  font-size: 12px; font-weight: 700; padding: 5px 14px; border-radius: 999px;
  box-shadow: 0 6px 16px rgba(79,70,229,.4);
}
.plan h3 { font-size: 19px; margin-bottom: 4px; }
.plan .who { font-size: 13px; color: var(--text-3); min-height: 36px; margin-bottom: 14px; }
.plan .price { font-size: 40px; font-weight: 800; letter-spacing: -.03em; }
.plan .price small { font-size: 15px; font-weight: 600; color: var(--text-3); }
.plan .kzt { font-size: 13px; color: var(--text-3); margin-bottom: 18px; }
.plan ul { list-style: none; display: grid; gap: 11px; margin-bottom: 22px; flex: 1; }
.plan ul li { font-size: 14px; color: var(--text-2); display: flex; gap: 9px; align-items: flex-start; }
.plan ul li::before { content: "✓"; color: var(--emerald-500); font-weight: 800; }

/* Telegram band */
.tg-band {
  background: linear-gradient(135deg, var(--navy-900), var(--navy-700));
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 48px;
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; align-items: center;
}
.tg-band h2 { font-size: 32px; letter-spacing: -.02em; margin-bottom: 14px; }
.tg-band p { color: rgba(255,255,255,.72); font-size: 17px; margin-bottom: 22px; }
.tg-menu { display: grid; gap: 10px; }
.tg-btn { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); border-radius: 12px; padding: 13px 16px; font-size: 14px; display: flex; align-items: center; gap: 10px; }

/* Disclaimer */
.disclaimer {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: var(--radius);
  padding: 22px 24px;
  display: flex; gap: 16px; align-items: flex-start;
  font-size: 14px; color: #92400e;
}
.disclaimer .ic { font-size: 24px; }

/* Footer */
.site-footer { background: var(--navy-900); color: rgba(255,255,255,.7); padding: 56px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 36px; }
.footer-grid h4 { color: #fff; font-size: 14px; margin-bottom: 14px; text-transform: uppercase; letter-spacing: .05em; }
.footer-grid a { display: block; font-size: 14px; padding: 5px 0; color: rgba(255,255,255,.6); }
.footer-grid a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 22px; display: flex; justify-content: space-between; font-size: 13px; color: rgba(255,255,255,.45); flex-wrap: wrap; gap: 10px; }

/* ---------- Auth pages ---------- */
.auth-wrap { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-aside {
  background: linear-gradient(160deg, var(--navy-900), var(--navy-700));
  color: #fff;
  padding: 56px 52px;
  display: flex; flex-direction: column; justify-content: space-between;
  position: relative; overflow: hidden;
}
.auth-aside::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(600px 300px at 90% 10%, rgba(99,102,241,.4), transparent 60%);
  pointer-events: none;
}
.auth-aside .brand { color: #fff; position: relative; z-index: 1; }
.auth-aside-body { position: relative; z-index: 1; }
.auth-aside h2 { font-size: 32px; line-height: 1.2; margin-bottom: 18px; letter-spacing: -.02em; }
.auth-aside .feat { display: flex; gap: 12px; margin-bottom: 16px; font-size: 15px; color: rgba(255,255,255,.82); }
.auth-aside .feat .ic { color: var(--emerald-400); font-weight: 800; }
.auth-quote { position: relative; z-index: 1; font-size: 14px; color: rgba(255,255,255,.6); border-left: 3px solid var(--indigo-400); padding-left: 14px; }

.auth-main { display: flex; align-items: center; justify-content: center; padding: 40px; }
.auth-card { width: 100%; max-width: 420px; }
.auth-card h1 { font-size: 28px; letter-spacing: -.02em; margin-bottom: 6px; }
.auth-card .sub { color: var(--text-2); margin-bottom: 28px; font-size: 15px; }

.tabs { display: flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 4px; margin-bottom: 26px; }
.tabs button {
  flex: 1; font: inherit; font-weight: 600; font-size: 14px;
  padding: 10px; border: 0; background: transparent; border-radius: 9px;
  cursor: pointer; color: var(--text-2); transition: all .15s;
}
.tabs button.active { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }

.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 7px; color: var(--text-2); }
.field input, .field select {
  width: 100%; font: inherit; font-size: 15px;
  padding: 12px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field select:focus {
  outline: 0; border-color: var(--indigo-500);
  box-shadow: 0 0 0 3px rgba(99,102,241,.16);
}
.field .hint { font-size: 12px; color: var(--text-3); margin-top: 6px; }
.field.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field.two > div { margin: 0; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--text-2); margin-bottom: 20px; }
.check input { margin-top: 2px; width: 16px; height: 16px; accent-color: var(--indigo-600); }
.auth-foot { text-align: center; margin-top: 20px; font-size: 14px; color: var(--text-2); }
.auth-foot a { color: var(--indigo-600); font-weight: 600; }

.hidden { display: none !important; }

/* Tariff step (after register) */
.tariff-step { min-height: 100vh; background: var(--bg); padding: 48px 24px; }
.tariff-step .stepper { max-width: 1080px; margin: 0 auto 8px; display: flex; align-items: center; gap: 12px; justify-content: center; color: var(--text-3); font-size: 14px; }
.tariff-step .stepper b { color: var(--emerald-500); }

/* ---------- App / dashboard ---------- */
.app-shell { display: grid; grid-template-columns: 260px 1fr; min-height: 100vh; }
.sidebar {
  background: var(--navy-900);
  color: rgba(255,255,255,.72);
  padding: 22px 16px;
  display: flex; flex-direction: column;
  position: sticky; top: 0; height: 100vh;
}
.sidebar .brand { color: #fff; padding: 4px 8px 22px; }
.side-nav { display: flex; flex-direction: column; gap: 3px; overflow-y: auto; flex: 1; }
.side-nav .group-label { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: rgba(255,255,255,.35); padding: 16px 12px 6px; }
.side-nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 10px;
  font-size: 14.5px; font-weight: 500;
  color: rgba(255,255,255,.72);
  transition: background .15s, color .15s;
  cursor: pointer;
}
.side-nav a .ic { width: 20px; text-align: center; font-size: 16px; }
.side-nav a:hover { background: rgba(255,255,255,.07); color: #fff; }
.side-nav a.active { background: var(--indigo-600); color: #fff; box-shadow: 0 6px 16px rgba(79,70,229,.4); }
.side-upgrade { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); border-radius: 12px; padding: 14px; margin-top: 12px; }
.side-upgrade p { font-size: 12.5px; color: rgba(255,255,255,.6); margin-bottom: 10px; }
.side-upgrade .bar { height: 6px; background: rgba(255,255,255,.12); border-radius: 999px; overflow: hidden; margin-bottom: 10px; }
.side-upgrade .bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--emerald-400), var(--emerald-500)); }

.app-main { display: flex; flex-direction: column; min-width: 0; }
.app-header {
  height: 68px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: 18px;
  padding: 0 28px;
  position: sticky; top: 0; z-index: 20;
}
.app-search { flex: 1; max-width: 460px; position: relative; }
.app-search input {
  width: 100%; font: inherit; font-size: 14px;
  padding: 10px 14px 10px 40px;
  border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2);
}
.app-search input:focus { outline: 0; border-color: var(--indigo-400); background: #fff; }
.app-search .ic { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--text-3); }
.app-header .spacer { flex: 1; }
.plan-badge { font-size: 12px; font-weight: 700; color: var(--indigo-600); background: rgba(99,102,241,.1); border: 1px solid rgba(99,102,241,.2); padding: 6px 12px; border-radius: 999px; }
.icon-btn { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface); cursor: pointer; display: grid; place-items: center; font-size: 17px; position: relative; }
.icon-btn:hover { background: var(--surface-2); }
.icon-btn .dot { position: absolute; top: 8px; right: 9px; width: 8px; height: 8px; background: var(--rose-500); border-radius: 50%; border: 2px solid var(--surface); }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, var(--indigo-500), var(--emerald-500)); color: #fff; display: grid; place-items: center; font-weight: 700; cursor: pointer; }

.app-body { padding: 28px; overflow-y: auto; }
.page-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; flex-wrap: wrap; gap: 14px; }
.page-title h1 { font-size: 26px; letter-spacing: -.02em; }
.page-title p { color: var(--text-2); font-size: 15px; margin-top: 3px; }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 24px; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; }
.stat-card .label { font-size: 13px; color: var(--text-3); display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.stat-card .value { font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.stat-card .delta { font-size: 12.5px; margin-top: 6px; font-weight: 600; }
.stat-card .delta.up { color: var(--emerald-500); }
.stat-card .delta.muted { color: var(--text-3); }

.grid-2 { display: grid; grid-template-columns: 1.6fr 1fr; gap: 18px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; }
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.card-head h3 { font-size: 17px; }
.card-head a { font-size: 13px; color: var(--indigo-600); font-weight: 600; }

.doc-row { display: flex; align-items: center; gap: 14px; padding: 13px 0; border-bottom: 1px solid var(--border); }
.doc-row:last-child { border-bottom: 0; }
.doc-ic { width: 40px; height: 40px; border-radius: 10px; background: rgba(99,102,241,.1); display: grid; place-items: center; font-size: 18px; flex-shrink: 0; }
.doc-row .meta { flex: 1; min-width: 0; }
.doc-row .meta b { font-size: 14.5px; font-weight: 600; display: block; }
.doc-row .meta span { font-size: 12.5px; color: var(--text-3); }

.task-item { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); align-items: flex-start; }
.task-item:last-child { border-bottom: 0; }
.task-item input { margin-top: 3px; width: 17px; height: 17px; accent-color: var(--indigo-600); }
.task-item .t-body { flex: 1; }
.task-item .t-body b { font-size: 14px; font-weight: 600; display: block; }
.task-item .t-body span { font-size: 12.5px; }
.due { font-weight: 700; }
.due.soon { color: var(--rose-500); }
.due.ok { color: var(--text-3); }

.quick-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.quick {
  border: 1px solid var(--border); border-radius: 12px; padding: 16px;
  display: flex; flex-direction: column; gap: 8px; cursor: pointer;
  transition: border-color .15s, background .15s, transform .12s;
}
.quick:hover { border-color: var(--indigo-400); background: rgba(99,102,241,.04); transform: translateY(-2px); }
.quick .ic { font-size: 22px; }
.quick b { font-size: 14px; }
.quick span { font-size: 12px; color: var(--text-3); }

.placeholder { text-align: center; padding: 70px 20px; color: var(--text-3); }
.placeholder .ic { font-size: 46px; margin-bottom: 14px; }
.placeholder h3 { color: var(--text); font-size: 20px; margin-bottom: 8px; }
.placeholder p { max-width: 420px; margin: 0 auto 18px; }

/* mobile menu toggle (app) */
.menu-toggle { display: none; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { transform: none; max-width: 460px; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .pricing-grid { grid-template-columns: repeat(2, 1fr); }
  .tg-band { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-aside { display: none; }
}
@media (max-width: 720px) {
  .nav-links { display: none; }
  .hero h1 { font-size: 38px; }
  .section-head h2 { font-size: 30px; }
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; z-index: 100; width: 260px; transform: translateX(-100%); transition: transform .2s; }
  .sidebar.open { transform: translateX(0); }
  .menu-toggle { display: grid; }
  .features-grid, .pricing-grid, .steps { grid-template-columns: 1fr; }
}
