/* Logidex Exit-Intent Popup — универсальный виджет.
   Подключение: <link rel="stylesheet" href="/assets/lib/exit-intent-popup.css">
   Не использует внешние шрифты/иконки. Все цвета — CSS-переменные с фолбэками
   на фирменный фиолетовый бренда Logidex (#8e73fe). */

.leip-overlay{
  position:fixed;inset:0;
  background:rgba(15,15,30,.55);
  backdrop-filter:blur(4px);
  -webkit-backdrop-filter:blur(4px);
  display:flex;align-items:center;justify-content:center;
  padding:20px;
  z-index:100000;
  opacity:0;
  transition:opacity .2s ease-out;
  font-family:'TildaSans',-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;
}
.leip-overlay.leip-visible{opacity:1}

.leip-card{
  background:#fff;
  border-radius:12px;
  box-shadow:0 20px 60px rgba(0,0,0,.28);
  max-width:480px;width:100%;
  padding:28px 28px 24px;
  position:relative;
  transform:translateY(12px) scale(.98);
  transition:transform .2s ease-out;
  max-height:calc(100vh - 40px);
  overflow-y:auto;
  -webkit-overflow-scrolling:touch;
}
.leip-overlay.leip-visible .leip-card{transform:translateY(0) scale(1)}

.leip-close{
  position:absolute;top:10px;right:12px;
  width:32px;height:32px;
  background:none;border:none;cursor:pointer;
  font-size:22px;line-height:1;
  color:#999;
  border-radius:6px;
  transition:background .15s,color .15s;
  display:flex;align-items:center;justify-content:center;
}
.leip-close:hover{background:#f3f0ff;color:#222}
.leip-close:focus-visible{outline:2px solid #8e73fe;outline-offset:2px}

.leip-icon{
  width:44px;height:44px;
  border-radius:11px;
  background:linear-gradient(135deg,#8e73fe,#a78bfa);
  display:flex;align-items:center;justify-content:center;
  margin:0 0 14px;
}
.leip-icon svg{width:24px;height:24px;stroke:#fff;fill:none;stroke-width:2}

.leip-title{
  font-size:21px;font-weight:700;
  color:#1a1a2e;line-height:1.25;
  margin:0 0 10px;
  padding-right:20px;
}
.leip-body{
  font-size:15px;line-height:1.55;
  color:#4a4a5e;
  margin:0 0 18px;
}

.leip-form{display:flex;flex-direction:column;gap:10px;margin:0 0 14px}
.leip-input,.leip-select{
  width:100%;
  padding:12px 14px;
  border:2px solid #e8e3ff;
  border-radius:10px;
  font-size:15px;
  font-family:inherit;
  outline:none;
  color:#222;
  background:#fff;
  transition:border-color .15s,box-shadow .15s;
  -webkit-appearance:none;appearance:none;
}
.leip-input:focus,.leip-select:focus{
  border-color:#8e73fe;
  box-shadow:0 0 0 3px rgba(142,115,254,.15);
}
.leip-input::placeholder{color:#9a9aae}
.leip-select{
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='none' stroke='%238e73fe' stroke-width='2' d='M1 1l5 5 5-5'/></svg>");
  background-repeat:no-repeat;
  background-position:right 14px center;
  padding-right:36px;
}
.leip-phone-label{
  display:flex;align-items:center;gap:6px;
  font-size:13px;color:#666;
  margin:0 0 2px 2px;
}

.leip-submit{
  width:100%;
  padding:14px 18px;
  min-height:48px;
  background:#8e73fe;color:#fff;
  border:none;border-radius:10px;
  font-size:15px;font-weight:700;
  font-family:inherit;
  cursor:pointer;
  transition:background .15s,transform .1s;
  display:flex;align-items:center;justify-content:center;gap:6px;
}
.leip-submit:hover:not(:disabled){background:#7359e6}
.leip-submit:active:not(:disabled){transform:scale(.98)}
.leip-submit:disabled{opacity:.6;cursor:default}

.leip-decline{
  width:100%;
  margin:8px 0 0;
  padding:10px 14px;
  background:transparent;
  border:none;
  border-radius:8px;
  color:#8a8aa0;
  font-size:14px;
  font-family:inherit;
  cursor:pointer;
  transition:color .15s,background .15s;
}
.leip-decline:hover{color:#555;background:#f7f6fb}
.leip-decline:focus-visible{outline:2px solid #8e73fe;outline-offset:2px}

.leip-err{
  display:none;
  margin:6px 0 0;
  padding:8px 12px;
  background:#fdecec;color:#c22;
  border-radius:8px;
  font-size:13px;
  line-height:1.4;
}
.leip-err.leip-show{display:block}

.leip-tg{
  margin:12px 0 0;
  font-size:13px;color:#666;
  text-align:center;
}
.leip-tg a{color:#8e73fe;font-weight:600;text-decoration:none}
.leip-tg a:hover{text-decoration:underline}

.leip-footnote{
  margin:14px 0 0;
  padding-top:12px;
  border-top:1px solid #f0edfa;
  font-size:12px;color:#999;
  text-align:center;
  line-height:1.4;
}

/* Thank-you screen */
.leip-thanks{text-align:center;padding:8px 0 4px}
.leip-thanks .leip-icon{
  margin:0 auto 14px;
  background:linear-gradient(135deg,#4caf50,#7fd882);
}
.leip-thanks h3{
  font-size:20px;font-weight:700;color:#1a1a2e;
  margin:0 0 8px;
}
.leip-thanks p{
  font-size:15px;color:#4a4a5e;line-height:1.5;
  margin:0 0 18px;
}
.leip-thanks .leip-tg{margin:0}

/* Mobile */
@media(max-width:520px){
  .leip-overlay{padding:10px}
  .leip-card{padding:22px 20px 20px;border-radius:12px;max-width:none}
  .leip-title{font-size:18px;padding-right:24px}
  .leip-body{font-size:14px}
  .leip-input,.leip-select{font-size:15px;padding:12px 12px}
  .leip-submit{font-size:15px;padding:13px 16px;min-height:44px}
}
