/* ════════════════════════════════════════════════════════════════
   Агент БФЛ — дизайн-система. Светлая «IT-tech» тема, фиолетовый акцент.
   Базовые токены + компоненты + публичные страницы. Кабинет — portal.css.
   ════════════════════════════════════════════════════════════════ */
:root {
  --bg:        #ffffff;
  --bg-soft:   #f6f7fb;          /* альтернативные секции */
  --bg-grid:   rgba(17,20,30,.035);
  --panel:     #ffffff;
  --panel-2:   #f3f4f8;          /* инпуты, hover */
  --line:      #e9eaf0;
  --line-2:    #dfe1ea;

  --text:      #0d0f16;
  --muted:     #565d6e;
  --faint:     #8b93a3;

  --brand:     #6d28d9;          /* violet-700 */
  --brand-2:   #5b21b6;
  --brand-3:   #7c3aed;
  --brand-tint:#f4effe;          /* очень светлый фиолетовый фон */
  --accent:    #c026d3;
  --grad:      linear-gradient(135deg, #7c3aed 0%, #a21caf 100%);

  --ok:        #059669;
  --warn:      #d97706;
  --danger:    #e11d48;

  --radius:    16px;
  --radius-sm: 11px;
  --sh-sm:     0 1px 2px rgba(13,15,22,.06), 0 1px 1px rgba(13,15,22,.04);
  --sh-md:     0 4px 12px -2px rgba(13,15,22,.08), 0 12px 32px -12px rgba(13,15,22,.12);
  --sh-lg:     0 24px 60px -20px rgba(76,29,149,.28);
  --ring:      0 0 0 4px rgba(124,58,237,.14);

  --font:      'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --display:   'Space Grotesk', var(--font);
  --mono:      'Space Grotesk', ui-monospace, 'SF Mono', Menlo, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg); color: var(--text);
  font-family: var(--font); font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  min-height: 100vh;
}
h1, h2, h3, .display { font-family: var(--display); }

a { color: var(--brand); text-decoration: none; transition: color .15s; }
a:hover { color: var(--brand-2); }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

/* ─── header ─── */
header.site {
  position: sticky; top: 0; z-index: 20;
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.82); backdrop-filter: blur(14px) saturate(160%);
}
header.site .wrap { display: flex; align-items: center; gap: 28px; height: 68px; }
.logo { font-family: var(--display); font-weight: 700; font-size: 19px; letter-spacing: -.4px; color: var(--text); text-decoration: none; }
.logo:hover { color: var(--text); }
.logo span { color: var(--brand); }
.nav { display: flex; gap: 26px; margin-left: 8px; }
.nav a { color: var(--muted); font-size: 14.5px; font-weight: 500; }
.nav a:hover { color: var(--text); }
.header-cta { margin-left: auto; display: flex; align-items: center; gap: 12px; }
@media (max-width: 760px) { .nav { display: none; } header.site .wrap { gap: 12px; } }

/* ─── кнопки ─── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid transparent; border-radius: var(--radius-sm);
  padding: 12px 22px; font-size: 15px; font-weight: 600; font-family: inherit; cursor: pointer;
  color: #fff; background: var(--grad);
  box-shadow: 0 6px 18px -6px rgba(124,58,237,.5); transition: transform .15s, box-shadow .2s, filter .2s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 12px 26px -8px rgba(124,58,237,.6); filter: brightness(1.05); color: #fff; }
.btn:active { transform: translateY(0); }
.btn.ghost { background: #fff; color: var(--text); border-color: var(--line-2); box-shadow: var(--sh-sm); }
.btn.ghost:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-tint); }
.btn.block { width: 100%; }
.btn.sm { padding: 8px 14px; font-size: 13px; border-radius: 9px; }
.btn:disabled { opacity: .55; cursor: default; transform: none; filter: none; }

/* ─── HERO (двухколоночный) ─── */
.hero { position: relative; padding: 76px 0 64px; overflow: hidden; }
.hero::before {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background-image: radial-gradient(var(--bg-grid) 1px, transparent 1px);
  background-size: 26px 26px; -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent 92%);
  mask-image: linear-gradient(to bottom, #000 30%, transparent 92%);
}
.hero::after {
  content: ''; position: absolute; top: -120px; right: -120px; width: 520px; height: 520px; z-index: -1;
  background: radial-gradient(circle, rgba(124,58,237,.16), transparent 62%); pointer-events: none;
}
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
@media (max-width: 920px) { .hero-grid { grid-template-columns: 1fr; gap: 40px; } }

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 22px;
  padding: 6px 14px; border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--brand);
  background: var(--brand-tint); border: 1px solid #e6dbfb;
}
.eyebrow .pulse { width: 7px; height: 7px; border-radius: 50%; background: var(--brand-3); box-shadow: 0 0 0 0 rgba(124,58,237,.5); animation: pulse 2s infinite; }
@keyframes pulse { 0%{box-shadow:0 0 0 0 rgba(124,58,237,.45)} 70%{box-shadow:0 0 0 8px rgba(124,58,237,0)} 100%{box-shadow:0 0 0 0 rgba(124,58,237,0)} }

.hero h1 { font-size: 52px; line-height: 1.06; margin: 0 0 20px; font-weight: 700; letter-spacing: -1.6px; }
.hero h1 .grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 19px; color: var(--muted); max-width: 540px; margin: 0 0 30px; }
.hero .cta { display: flex; gap: 14px; flex-wrap: wrap; }
@media (max-width: 920px) { .hero { text-align: center; } .hero p.lead { margin-inline: auto; } .hero .cta { justify-content: center; } }
@media (max-width: 560px) { .hero h1 { font-size: 36px; letter-spacing: -.6px; } .hero p.lead { font-size: 17px; } }

/* мок кабинета в герое */
.mock {
  background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--sh-lg);
  overflow: hidden; transform: perspective(1400px) rotateY(-8deg) rotateX(3deg); transition: transform .4s;
}
.mock:hover { transform: perspective(1400px) rotateY(0) rotateX(0); }
@media (max-width: 920px) { .mock { transform: none; } }
.mock-head { display: flex; align-items: center; gap: 7px; padding: 13px 16px; border-bottom: 1px solid var(--line); background: var(--bg-soft); }
.mock-dot { width: 11px; height: 11px; border-radius: 50%; background: #d6d9e3; }
.mock-head .mock-title { margin-left: 10px; font-size: 12.5px; color: var(--faint); font-family: var(--mono); }
.mock-body { padding: 18px; }
.mock-tiles { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; margin-bottom: 16px; }
.mock-tile { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; padding: 13px; }
.mock-tile .l { font-size: 11px; color: var(--faint); margin-bottom: 6px; }
.mock-tile .v { font-size: 19px; font-weight: 700; font-family: var(--display); letter-spacing: -.5px; }
.mock-tile.accent .v { color: var(--brand); }
.mock-list { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.mock-row { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; font-size: 13px; border-bottom: 1px solid var(--line); }
.mock-row:last-child { border-bottom: none; }
.mock-row .nm { font-weight: 500; }
.chip { font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px; }
.chip.v { background: var(--brand-tint); color: var(--brand); }
.chip.g { background: #e7f7f0; color: #047857; }
.chip.y { background: #fdf2dc; color: #b45309; }

/* ─── strip / плюсы (в одну строку) ─── */
.strip { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 36px; padding: 26px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.strip .it { display: flex; align-items: center; gap: 9px; font-size: 15px; font-weight: 500; color: var(--text); }
.strip .it::before { content: '✓'; flex: none; display: inline-flex; width: 22px; height: 22px; border-radius: 7px; background: var(--brand-tint); color: var(--brand); align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }

/* ─── секции ─── */
section { padding: 76px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 48px; }
.section-tag { font-size: 13px; font-weight: 600; color: var(--brand); text-transform: uppercase; letter-spacing: 1px; }
.section-title { font-size: 36px; margin: 10px 0 12px; font-weight: 700; letter-spacing: -1px; }
.section-sub { color: var(--muted); margin: 0; font-size: 17px; }
@media (max-width: 560px) { .section-title { font-size: 27px; } section { padding: 54px 0; } }

.alt { background: var(--bg-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.grid { display: grid; gap: 20px; }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 820px) { .grid.cols-3 { grid-template-columns: 1fr; } }

/* карточки шагов */
.card { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--sh-sm); transition: transform .2s, box-shadow .2s, border-color .2s; }
.card:hover { transform: translateY(-4px); box-shadow: var(--sh-md); border-color: #d9d3f0; }
.card h3 { margin: 0 0 10px; font-size: 19px; font-weight: 600; }
.card p { margin: 0; color: var(--muted); }
.step-num { display: inline-flex; width: 46px; height: 46px; border-radius: 13px; font-size: 20px; background: var(--brand-tint); color: var(--brand); align-items: center; justify-content: center; margin-bottom: 16px; font-weight: 700; font-family: var(--display); }

/* блок выплат */
.payout { display: grid; grid-template-columns: 1fr 1.1fr; gap: 44px; align-items: center; }
@media (max-width: 820px) { .payout { grid-template-columns: 1fr; gap: 28px; } }
.payout-card { background: var(--grad); border-radius: 22px; padding: 40px; color: #fff; box-shadow: var(--sh-lg); }
.payout-card .big { font-family: var(--display); font-size: 38px; font-weight: 700; letter-spacing: -1px; line-height: 1.05; }
.payout-card .cap { opacity: .9; margin-top: 10px; }
.payout ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.payout li { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; }
.payout li .ck { flex: none; width: 24px; height: 24px; border-radius: 7px; background: var(--brand-tint); color: var(--brand); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; }
.payout li b { font-weight: 600; }
.payout li span { color: var(--muted); }

/* FAQ */
.faq { max-width: 760px; margin: 0 auto; display: grid; gap: 12px; }
.faq details { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 4px 20px; box-shadow: var(--sh-sm); }
.faq summary { list-style: none; cursor: pointer; padding: 16px 0; font-weight: 600; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; color: var(--brand); font-size: 22px; font-weight: 400; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 18px; color: var(--muted); }

/* CTA-баннер */
.cta-banner { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding: 40px 44px; border-radius: 22px; background: var(--brand-tint); border: 1px solid #e6dbfb; }
.cta-banner h3 { margin: 0 0 6px; font-size: 24px; font-weight: 700; }
.cta-banner p { margin: 0; color: var(--muted); }

/* ─── формы ─── */
.form-card { position: relative; max-width: 460px; margin: 0 auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; box-shadow: var(--sh-md); }
.form-card h2 { margin: 0 0 6px; font-size: 25px; font-weight: 700; letter-spacing: -.5px; }
.form-card .sub { color: var(--muted); margin: 0 0 24px; font-size: 15px; }
.field { margin-bottom: 17px; }
.field label { display: block; font-size: 13px; font-weight: 500; color: var(--muted); margin-bottom: 7px; }
.field input, .field textarea, .field select {
  width: 100%; background: #fff; border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  padding: 12px 14px; color: var(--text); font-size: 15px; font-family: inherit; transition: border-color .15s, box-shadow .15s;
}
.field input::placeholder, .field textarea::placeholder { color: var(--faint); }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--brand); box-shadow: var(--ring); }
.field textarea { resize: vertical; min-height: 84px; }
.field .hint { font-size: 12px; color: var(--faint); margin-top: 6px; }
.checkbox { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--muted); cursor: pointer; }
.checkbox input { width: 18px; height: 18px; margin-top: 1px; flex: none; accent-color: var(--brand); }

.msg { padding: 12px 15px; border-radius: var(--radius-sm); margin-bottom: 16px; font-size: 14px; display: none; }
.msg.show { display: block; }
.msg.err { background: #fdeef1; color: #be123c; border: 1px solid #f8cdd7; }
.msg.ok  { background: #e8f7f0; color: #047857; border: 1px solid #c2ebd8; }

.form-foot { text-align: center; margin-top: 20px; font-size: 14px; color: var(--muted); }
.hidden { display: none !important; }
footer.site { border-top: 1px solid var(--line); color: var(--faint); font-size: 13px; padding: 32px 0; text-align: center; }

/* ─── модалка ─── */
.modal-backdrop { position: fixed; inset: 0; z-index: 60; background: rgba(13,15,22,.4); backdrop-filter: blur(4px); display: flex; align-items: flex-start; justify-content: center; padding: 56px 16px; overflow: auto; animation: fade .2s ease; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.modal-backdrop.hidden { display: none !important; }
.modal { position: relative; margin: 0; animation: pop .22s cubic-bezier(.2,.8,.3,1.1); }
@keyframes pop { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-close { position: absolute; top: 14px; right: 14px; width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line-2); background: #fff; color: var(--muted); font-size: 22px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: .15s; }
.modal-close:hover { color: var(--brand); border-color: var(--brand); background: var(--brand-tint); }
