/* ==========================================================================
   ========== БАЗА / ПЕРЕМЕННЫЕ / ОСНОВНОЙ ЛЕЙАУТ ===========================
   ========================================================================== */
:root{
  --container: 1350px;
  --pad: 15px;
  --bg: #0f1224;
  --ink: #13183d;
  --muted:#71778a;
  --brand:#ffdd00;
  --brand-ink:#13183d;
  --white:#fff;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  min-height:100vh;
  display:flex;
  flex-direction:column;
  font:16px/1.5 system-ui,-apple-system,Segoe UI,Roboto,Arial;
  color:var(--ink);
  background:#fff;
}
main{ flex:1 0 auto; background:#fff; }
.container{ max-width:var(--container); padding:0 var(--pad); margin:0 auto; }


/* ==========================================================================
   ========== ХЕДЕР ==========================================================
   ========================================================================== */
.site-header{
  position:static;
  background:#fff;
  border-bottom:1px solid #eef0f3;
}
.header-inner{ display:flex; align-items:center; gap:16px; min-height:72px; }
.logo img{ height:42px; display:block; }

/* Кнопка «Войти» (иконка над текстом) */
.login-link{
  margin-left:auto;
  display:flex; flex-direction:column; align-items:center; gap:4px;
  text-decoration:none; color:#1e1e1e;
}
.login-icon{ width:22px; height:22px; display:block; }
.login-text{ font-weight:600; font-size:12px; line-height:1; }

/* Телефон и бургер (одинаковая кнопка-капсула) */
.burger,
.phone-btn{
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:5px;
  width:44px; height:44px;
  border-radius:12px; border:1px solid rgba(0,0,0,.1);
  background:transparent; cursor:pointer;
  text-decoration:none; color:#222;
}
/* Раскладка справа */
.header-inner > .phone-btn{ margin-left:auto; }
.header-inner > .login-link + .phone-btn{ margin-left:10px; }
.header-inner > .phone-btn + .burger{ margin-left:10px; }
/* Иконки внутри капсул */
.burger span{ width:20px; height:2px; background:#222; border-radius:2px; display:block; }
.phone-icon{ width:20px; height:20px; display:block; }

/* Узкие экраны — компактнее */
@media (max-width:420px){
  .logo img{height:36px}
  .burger, .phone-btn{width:40px; height:40px}
  .burger span{width:18px}
  .phone-icon{width:18px; height:18px}
  .login-text{font-size:11px}
}


/* ==========================================================================
   ========== ОФФКАНВАС-МЕНЮ (дровер + оверлей) =============================
   ========================================================================== */
.nav-overlay{
  position:fixed; inset:0; background:rgba(0,0,0,.35);
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
  z-index:99;
}
.nav-drawer{
  position:fixed; top:0; right:0; height:100vh; width:360px; max-width:88vw;
  background:#fff; color:#111; z-index:100;
  box-shadow:-8px 0 24px rgba(0,0,0,.15);
  transform:translateX(100%); transition:transform .35s ease;
  display:flex; flex-direction:column; padding:18px 18px 24px;
}
.drawer-close{
  margin-left:auto; width:40px; height:40px; border:0; background:transparent;
  font-size:32px; line-height:40px; color:#111; cursor:pointer;
}
.drawer-nav ul{ list-style:none; margin:8px 0 0; padding:0; display:flex; flex-direction:column; gap:14px; }
.drawer-nav a{
  text-decoration:none; color:#111; display:block; padding:12px 10px; border-radius:12px;
  font-weight:700; letter-spacing:.02em; text-transform:uppercase;
  transition:transform .18s ease;
}
.drawer-nav a:hover{ transform:translateX(6px); }

/* Состояния открытия */
.is-menu-open .nav-drawer{ transform:translateX(0); }
.is-menu-open .nav-overlay{ display:block !important; }
.is-menu-open{ overflow:hidden; }
.nav-overlay[hidden]{ display:none !important; }


/* ==========================================================================
   ========== КНОПКИ ========================================================
   ========================================================================== */
.btn{
  display:inline-block; padding:12px 18px; border-radius:10px;
  text-decoration:none; cursor:pointer; border:1px solid transparent;
  font-weight:600;
}
.btn-primary{ background:var(--brand); color:var(--brand-ink); }
.btn-primary:hover{ filter:brightness(0.95); }
.btn-ghost{ background:transparent; color:#fff; border-color:#fff; }
.btn-ghost:hover{ background:rgba(255,255,255,.08); }


/* ==========================================================================
   ========== ФУТЕР: ОСНОВА ==================================================
   ========================================================================== */
.site-footer{ background:#0e1425; color:#cfd5e3; padding:48px 0 24px; }
.site-footer a{ color:inherit; text-decoration:none; }
.site-footer a:hover{ text-decoration:underline; }

/* Футер — шапка (меню + логотип) */
.footer-head{
  display:flex; align-items:center; justify-content:space-between;
  gap:24px; padding-bottom:24px; border-bottom:1px solid rgba(255,255,255,.08);
}
.footer-nav{ display:flex; gap:16px; flex-wrap:wrap; }
.footer-nav a{ opacity:.95; color:#fff; }
.footer-logo img{ height:60px; display:block; }

@media (max-width:900px){
  .footer-head{ flex-direction:column; align-items:flex-start; gap:14px; }
  .footer-logo{ order:1; margin-bottom:30px; }
  .footer-nav{ order:2; }
}

/* Футер — инфо-сетка */
.footer-grid{
  display:grid; gap:24px; margin:24px 0 8px;
  grid-template-columns: repeat(4, minmax(0,1fr));
}
.footer-col h4{ margin:0 0 10px; font-size:18px; color:#fff; }
.footer-col p{ margin:10px 0; font-size:12px; line-height:1.6; }
.footer-list{ list-style:none; margin:10px 0 0; padding:0; }
.footer-list li{ margin:6px 0; font-size:12px; line-height:1.5; }

@media (max-width:1024px){
  .footer-grid{ grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width:640px){
  .footer-grid{ grid-template-columns: 1fr; }
}

/* Футер — документы */
.footer-docs{
  background:#ffc933; color:#101522; border-radius:16px;
  padding:24px; margin:28px 0;
}
.footer-docs h3{ margin:0 0 14px; }
.docs-grid{
  list-style:none; margin:0; padding:0;
  display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px 24px;
}
.docs-grid a{
  display:flex; align-items:center; gap:10px; color:#101522; font-weight:600;
  line-height:14px; margin-bottom:10px;
}
.docs-grid a img{ height:22px; }
@media (max-width:700px){
  .docs-grid{ grid-template-columns:1fr; }
}

/* Футер — список кредиторов */
.creditors h3{ margin:18px 0 10px; }
.creditors-grid{
  display:grid; gap:10px 24px;
  grid-template-columns: repeat(3, minmax(0,1fr));
  margin:20px 0;
}
.creditor{
  font-size:12px; line-height:1;
  display:flex; align-items:center; flex-wrap:wrap; gap:8px;
}
.creditor .sep{ opacity:.6; }
.creditor .cred-inn{ opacity:.9; }
.creditors-toggle{
  margin:14px auto 0; display:inline-flex; align-items:center; gap:8px;
  background:transparent; color:#fff; border:1px solid rgba(255,255,255,.25);
  border-radius:10px; padding:8px 12px; cursor:pointer;
}
@media (max-width:900px){
  .creditors-grid{ grid-template-columns:1fr; }
}
.creditors-grid.is-collapsed .creditor.is-hidden{ display:none; }

/* Футер — нижняя полоса */
.footer-bottom{
  display:flex; align-items:center; justify-content:space-between; gap:20px;
  padding-top:22px; border-top:1px solid rgba(255,255,255,.08); margin-top:26px;
}
.footer-bottom .cookies-note{ font-size:13px; opacity:.9; margin:0; }
.footer-bottom .copy{ margin:0; opacity:.9; font-size:13px; }
@media (max-width:640px){
  .footer-bottom{ flex-direction:column; align-items:center; text-align:center; gap:10px; }
  .footer-bottom p{ margin:0; }
}

/* Кнопка «Наверх» */
.to-top{
  position:fixed; right:18px; bottom:18px; width:44px; height:44px;
  border-radius:50%; border:0; background:#ffc933; color:#333; display:none;
  cursor:pointer; border:5px solid #fff; font-size:22px;
}
.to-top.show{ display:block; }

/* Футер — крупные контакты в шапке футера */
.footer-contacts-main{
  display:flex; align-items:center; gap:28px;
}
.footer-contacts-main a{
  display:inline-flex; align-items:center; gap:10px;
  color:#fff; text-decoration:none; font-size:20px; font-weight:700; line-height:1.3;
}
.footer-contacts-main a:hover{ text-decoration:underline; }
.footer-icon{ width:22px; height:22px; flex-shrink:0; color:#ffc933; }
@media (max-width:900px){
  .footer-head{ flex-direction:column; align-items:flex-start; gap:16px; }
  .footer-logo{ order:1; }
  .footer-contacts-main{ order:2; flex-direction:column; align-items:flex-start; gap:10px; }
  .footer-contacts-main a{ font-size:18px; }
}

/* Цвет ссылок контактов (где используется .footer-contacts) */
.footer-contacts a{ color:#fff; }


/* ==========================================================================
   ========== COOKIE NOTICE (плашка куки) ===================================
   ========================================================================== */
.cc-wrap{
  position:fixed; left:0; right:0; bottom:0;
  z-index:2147483000;
  transform:translateY(110%);
  transition:transform .35s ease;
  pointer-events:none;
}
.cc-wrap.is-visible{ transform:translateY(0); pointer-events:auto; }

.cc-box{
  margin:12px auto; max-width:1200px;
  display:flex; gap:16px; align-items:center; justify-content:space-between;
  background:#fff; color:#8a96a8;
  border-radius:12px; padding:14px 16px;
  box-shadow:0 10px 30px rgba(0,0,0,.25);
}
.cc-text{ font-size:14px; line-height:1.45; }
.cc-text a{ text-decoration:underline; color:#878787; }
.cc-btn{
  flex:0 0 auto; border:0; border-radius:10px; padding:10px 14px;
  font-size:14px; cursor:pointer; background:#0b1533; color:#fff;
}
.cc-btn:focus{ outline:2px solid #86efac; outline-offset:2px; }

@media (max-width:700px){
  .cc-box{ flex-direction:column; align-items:stretch; gap:10px; border-radius:10px; }
  .cc-text{ font-size:10px; }
  .cc-btn{ width:100%; }
}


/* ==========================================================================
   ========== КАЛЬКУЛЯТОР (ВАЖНО: фиксы тумблера + дата) ====================
   ========================================================================== */

/* Подстраховка от переполнения содержимого карточки */
.calc--hero{ overflow:hidden; }

/* Контейнер переключателя внутри калькулятора: вписывается в ширину */
.calc--hero .loan-switch{
  width:100%;
  max-width:100%;
  box-sizing:border-box;
  margin:12px 0 16px;
}

/* Кнопки переключателя ужимаются равномерно, текст не переносится */
.calc--hero .loan-switch__btn{
  flex:1 1 0;
  min-width:0;
  white-space:nowrap;
}

/* Базовый вид «пилюли» переключателя */
.loan-switch{
  display:flex; align-items:center;
  gap:8px;
  background:#f6f8fb;
  padding:6px;
  border-radius:999px;
}

/* Сами кнопки */
.loan-switch__btn{
  border:0; border-radius:999px; cursor:pointer;
  background:#e9eef5; color:#0b1533;
  font-weight:700; line-height:1;
  font-size:clamp(13px, 3.2vw, 16px);
  padding:clamp(8px, 2.2vw, 12px) clamp(12px, 3.4vw, 18px);
  transition:background .2s ease, color .2s ease, box-shadow .2s ease;
}
.loan-switch__btn.is-active{
  background:#0b1533; color:#fff;
  box-shadow:0 6px 16px rgba(11,21,51,.22);
}

/* Мобильная подстройка — компактнее и без выезда за края */
@media (max-width:420px){
  .calc--hero{ padding-right:14px; padding-left:14px; }
  .calc--hero .loan-switch{ padding:5px; gap:6px; }
  .calc--hero .loan-switch__btn{ padding:12px 10px; font-size:clamp(12px, 3.6vw, 14px); }
}

/* Дата возврата — всегда в одну строку */
#dateOut{
  display:inline-block;
  white-space:nowrap;
  font-size:clamp(14px, 3.5vw, 18px);
  line-height:1.2;
}
