/* БАЗОВЫЕ СТИЛИ */
* { margin: 0; padding: 0; box-sizing: border-box; transition:color 0.3s ease, background 0.3s ease;}


.Hnone {display:none;}
.Hdisable {display:none!important;}


a {cursor: pointer;}
input {border:none;}

.input--cb {
    margin:0 0 10px 10px; 
    cursor:pointer;
    display: flex;
}

.input--cb input {margin:0px;}

/* Стили подсказок в input */
.input {
    position:relative;
    display: block;
    margin:0 0 20px 0;
}

.placeholder {
    position:absolute;
    left:15px;
    top:50%;
    transform:translateY(-60%);
    transition:all 0.3s ease;
}

.Hactive--input .placeholder, .placeholder.Hactive--input, input:-webkit-autofill + .placeholder, 
/* .placeholder:not(:placeholder-shown),  */
input:focus ~ .placeholder, .Herror-input .placeholder {
    font-size:12px;
    opacity:0.5;
    top:0px;
    transform:translateY(-50%);
}

/* Стили полей ввода */
input {
  width: 100%;
  padding: 1.1rem 3rem 1.1rem 1rem;
  border-radius: var(--radius);
border-bottom: 1px solid #767676;
background: #181818;
  color: var(--text);
  font-size: 1rem;
  outline: none;
  transition: border-color var(--speed);
}

.Herror-input input {
    border-bottom: 1px solid #d10808;
}
.Herror-input .placeholder {
    opacity:1!important;
}
.Herror-input .ph-text {
    background: #d10808;
    padding: 2px 5px 3px 5px;
    border-radius: 3px;
    line-height: 12px;
}
.Hactive--input input {
    border-bottom: 1px solid #1f6feb;
}

/* Иконки */
.svg--icon {
    width:100%;
    height:100%;
}
.svg--icon, .svg--icon path, .svg--icon rect, .svg--icon circle {
    transition:all 0.3s ease;
}

.svg--icon.cb {
    min-width: 16px;
    width: 16px;
    height: 16px;
    display: block;
    margin-top: 3px;
    margin-right: 8px;
}

.svg--icon.password {
    width:20px;
    height:20px;
}
.Hactive--opendata .chert {display:none;}






/* Обертки */
.Hwrap--submit {
    margin: 25px 0 10px 0;
}




/* Стили */
.Hcolor-trans {
    stroke:transparent;
}
.Hactive--input .Hcolor-trans, input:checked + .svg--icon .Hcolor-trans {
    stroke:#fff;
}


/* === 1. Базовые переменные и сброс ====================================== */
:root {
  --bg: #121212;
  --panel: #1e1e1e;
  --accent: #1f6feb;
  --text: #e0e0e0;
  --text-muted: #9a9a9a;
  --radius: 12px;
  --speed: 250ms;
  font-size: 16px;
}

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

body {
  min-height: 100vh;
  font-family: 'Segoe UI', Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  display: grid;
  place-items: center;
  padding: 1rem;
}

/* === 2. Каркас ========================================================== */
.auth {
  width: 100%;
  max-width: 420px;
  background: var(--panel);
  border-radius: var(--radius);
  padding: 2rem 2.25rem 2.5rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.auth__tabs {
  display: flex;
  margin-bottom: 1.5rem;
}

.auth__tab {
  flex: 1;
  padding: 0.75rem 0;
  border: none;
  background: transparent;
  color: var(--text-muted);
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: color var(--speed), border-color var(--speed);
}

.auth__tab_active {
  color: var(--text);
  border-color: var(--accent);
}

/* === 3. Формы =========================================================== */
/* .form {

} */

.form_active {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
}

/* Блок уведомлений в форме */
.form_msg {
    margin: 0 0 30px 0;
    padding: 20px;
    border-radius: 5px;
    border: 1px solid #545454;
    text-align: center;
}
.form_msg.Hmsg--error {
  color:#d10808;
}

/* option: при получении кода */
.form--code #codeWrap {
  display: block;
}

/* === 4. Поля с «плавающими» подсказками ================================= */
.field {
  position: relative;
}



.field__label {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
  transition: all var(--speed);
}

/* класс для «подъёма» подсказки */
.field__label_up {
  top: 0.35rem;
  transform: translateY(0);
  font-size: 0.75rem;
  color: var(--accent);
}


.field input:focus + .field__label,
.field input:not(:placeholder-shown) + .field__label {
  top: 0.35rem;
  font-size: 0.75rem;
  color: var(--accent);
}

/* === 5. Кнопка «показать пароль» ======================================= */
.field--password {
  position: relative;
}

.btn-password {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1.5rem;
  height: 1.5rem;
  background: transparent;
  border: none;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity var(--speed);
}

.field__toggle:hover {
  opacity: 1;
}

.field_hidden {
  display: none;
}

/* === 6. Чекбоксы и кнопки ============================================== */
.checkbox {
  display: flex;
  gap: 0.5rem;
  font-size: 0.9rem;
  user-select: none;
}

.checkbox input {
  accent-color: var(--accent);
  width:18px;
}

.btn {
  width: 100%;
  padding: 0.9rem;
  border: none;
  border-radius: var(--radius);
  background: var(--accent);
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  transition: background var(--speed), transform var(--speed);
}

.btn:hover {
  transform: translateY(-2px);
  background: #2380ff;
}

.text {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.text a {
  color: var(--accent);
  text-decoration: none;
}

/* === 7. Мобильная адаптация ============================================ */
@media (max-width: 480px) {
  .auth {
    padding: 1.5rem;
  }
}


/* общий сброс «жёлтой» заливки Chrome */
input:-webkit-autofill {
  /* цвет текста внутри поля */
  -webkit-text-fill-color: var(--text) !important;
  /* снимаем дефолтный inset‑box‑shadow */
  box-shadow: 0 0 0px 1000px var(--panel) inset !important;
  /* отключаем плавный переход браузера, чтобы не мигало */
  transition: background-color 5000s ease-in-out 0s !important;
}

/* чтобы перекрыть состояние при фокусе */
input:-webkit-autofill:focus {
  box-shadow: 0 0 0px 1000px var(--panel) inset !important;
}

/* анимация «мигания» часто происходит при hover */
input:-webkit-autofill:hover {
  box-shadow: 0 0 0px 1000px var(--panel) inset !important;
}












/* ТЕСТ */
/* Контейнер тумблера */
.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
}

/* Скрываем сам input */
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

/* Ползунок + дорожка */
.slider {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0; right: 0; bottom: 0;
  background: #ccc;
  transition: background 0.2s;
  border-radius: 24px;
}

/* Кнопка‑«шарик» */
.slider::before {
  content: "";
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  top: 3px;
  background: #fff;
  transition: transform 0.2s;
  border-radius: 50%;
}

/* Состояние «включён» */
.switch input:checked + .slider {
  background: #4caf50;  /* цвет фона когда вкл. */
}
.switch input:checked + .slider::before {
  transform: translateX(26px);
}

/* Фокус на клавиатуре */
.switch input:focus + .slider {
  box-shadow: 0 0 2px #4caf50;
}

/* Опционально: отключённое состояние */
.switch input:disabled + .slider {
  background: #888;
  cursor: not-allowed;
}
.switch input:disabled + .slider::before {
  background: #ccc;
}
