
:root {
  --accent: #9b1049;
  --accent-dark: #7d0c3b;
  --accent-soft: rgba(155, 16, 73, .14);
  --ink: #16233a;
  --muted: #5d6a7f;
  --line: #e9e9e9;
  --icon: #7b8699;
  --radius: 14px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: #fafafa;
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  line-height: 1.4;
}
h1, h2, p { margin: 0; }
img { display: block; max-width: 100%; }
a { color: inherit; }

.head-box {
    max-width: 90%;
    width: 1080px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #e9e9e9;
    padding: 15px 0;
}
.logo {
    display: flex;
    align-items: center;
}
.error-msg{     padding: 10px;
    border-radius: 10px;
    font-size: 14px;
    text-align: center;
    line-height: 20px;
    border: 1px solid #f1b8c4;
    background: #fdecef;
    color: #8a1230;
    margin: 0 10px 20px 10px;}
.status-msg{background: #eefbf0;
    padding: 15px;
        border: 1px solid #d5edd9;
    line-height: 20px;
    font-size: 14px;
    margin: 0px 10px 20px 10px;
    border-radius: 10px;
    text-align: center;}
.alert-msg-ok{background: #e6f7e9;
    padding: 10px;
    border: 1px solid #d3ead7;
    border-radius: 5px;
    margin: 0 0 20px 0;
    font-size: 14px;
    text-align: center;
    line-height: 22px;
    width: 100%;
    color: #38583e;}
/* ---------- страница ---------- */
.au-page {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 20px 20px 48px;
}


.au-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
}
.au-hero, .au-card { width: 100%; max-width: 520px; margin: 0 auto; }
.au-card-login {     width: 90%;
    max-width: 520px;
    margin: 40px auto;
    padding: 0 0; }
.au-actions{    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
        flex-direction: column;
}
/* ---------- заглавие + картинка ---------- */
.au-hero-title {
  font-size: clamp(2.1rem, 8.6vw, 2.9rem);
  line-height: 1.1;

  letter-spacing: -.02em;
}
.au-accent { display: block; color: var(--accent); }
.au-hero-sub { margin-top: 14px; font-size: 1.0625rem; line-height: 1.5; }
.au-hero-media {
  margin-top: 20px;
  /* aspect-ratio: 16 / 9; */
  /* border-radius: 18px; */
  /* overflow: hidden; */
  /* background: linear-gradient(135deg, #f3e3e8, #fbf1ea); */
}
.au-hero-media img { width: 100%; height: auto; object-fit: cover; }

/* ---------- карта ---------- */
.au-title { font-size: 1.625rem; line-height: 1.2;  letter-spacing: -.01em; }
.au-sub { margin-top: 8px; font-size: .9375rem; line-height: 1.5; color: var(--muted); }
.au-head { margin-bottom: 22px; }

.au-status { margin-bottom: 18px; }
.au-status:empty { display: none; }
.au-msg {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: .875rem;
  line-height: 1.5;
}
.au-msg--error { border-color: #f1b8c4; background: #fdecef; color: #8a1230; margin: 0 10px;}
.au-msg--warn { border-color: #efd48c; background: #fff6e0; color: #6b4e00; margin: 0 10px;}
.au-msg--success { border-color: #a9dbbd; background: #e8f6ee; color: #14532d; margin: 0 10px; }

/* ---------- полета ---------- */
.au-field { margin: 0 0 14px; }
.au-label { display: block; margin: 0 0 6px; font-size: .875rem; font-weight: 600; }
.au-req { color: var(--accent); }
.au-opt { font-weight: 400; color: var(--muted); }
.au-help { margin-top: 6px; font-size: .8125rem; line-height: 1.45; color: var(--muted); }
.au-sr {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.au-control { position: relative; }
.au-ico {
  width: 20px; height: 20px;
  fill: none; stroke: currentColor; stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round;
}
.au-control > .au-ico {
  position: absolute; top: 50%; left: 16px;
  transform: translateY(-50%);
  color: var(--icon);
  pointer-events: none;
}

.au-input, .au-select {
  display: block;
  width: 100%;
  height: 54px;
  margin: 0;
  padding: 0 16px 0 46px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background-color: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color .15s, box-shadow .15s;
}
.au-input::placeholder { color: #8a94a6; }
.au-input:focus, .au-select:focus {
  outline: 0;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.au-select {
  padding-right: 44px;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%237b8699' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 18px center;
}

.au-pass .au-input { padding-right: 54px; }
.au-pass-toggle {
  position: absolute; top: 50%; right: 6px;
  display: flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; padding: 0;
  border: 0; border-radius: 10px;
  background: transparent; color: var(--icon);
  cursor: pointer; transform: translateY(-50%);
}
.au-pass-toggle:hover { color: var(--ink); }
.au-pass-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }

/* ---------- чекбокс / редове ---------- */
.au-check { display: flex; align-items: flex-start; gap: 10px; font-size: .875rem; line-height: 1.45; cursor: pointer; }
.au-check input {
  flex: none; width: 20px; height: 20px; margin: 1px 0 0;
  border: 1.5px solid #b9c0cd; border-radius: 6px;
  background: #fff center / 12px no-repeat;
  cursor: pointer;
  -webkit-appearance: none; appearance: none;
  transition: background-color .15s, border-color .15s;
}
.au-check input:checked {
  border-color: var(--accent);
  background-color: var(--accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 10' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 5.2l3.2 3.2L11 1.6'/%3E%3C/svg%3E");
}
.au-check input:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.au-check a { color: var(--accent); font-weight: 600; }

.au-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 2px 0 20px; }
.au-row .au-check { align-items: center; }

.au-link {
  padding: 0; border: 0; background: none;
  color: var(--accent); font: inherit; font-size: .875rem; font-weight: 700;
  text-decoration: none; cursor: pointer;
}
.au-link:hover { text-decoration: underline; }
.au-back { margin-top: 18px; text-align: center; }

/* ---------- бутони ---------- */
.au-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; min-height: 54px; margin: 0; padding: 0 24px;
  border: 1.5px solid var(--line); border-radius: 999px;
  background: #fff; color: var(--ink);
  font: inherit; font-size: 1rem; font-weight: 600; line-height: 1.2;
  text-decoration: none; cursor: pointer;
  -webkit-appearance: none; appearance: none;
  transition: background-color .15s, border-color .15s, color .15s;
}
.au-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.au-btn--outline:hover { border-color: var(--accent); color: var(--accent); }
.au-btn--primary { border-color: var(--accent); background: var(--accent); color: #fff; }
.au-btn--primary:hover { border-color: var(--accent-dark); background: var(--accent-dark); }
.au-btn--submit { margin-top: 6px; }

.au-divider {
  display: flex; align-items: center; gap: 14px; margin: 20px 0;
  font-size: .8125rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
}
.au-divider::before, .au-divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* ---------- аватар ---------- */
.au-avatar-field { position: relative; margin-bottom: 18px; }
.au-file-input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.au-file-input:focus-visible + .au-avatar { outline: 2px solid var(--accent); outline-offset: 2px; }
.au-avatar {
  display: flex; align-items: center; gap: 14px; padding: 12px;
  border: 1px dashed #c4cad6; border-radius: var(--radius); cursor: pointer;
}
.au-avatar:hover { border-color: var(--accent); }
.au-avatar-img {
  display: flex; align-items: center; justify-content: center; flex: none;
  width: 56px; height: 56px; border-radius: 50%; overflow: hidden;
  background: #f0eef0; color: var(--icon);
}
.au-avatar-img img { width: 100%; height: 100%; object-fit: cover; }
.au-avatar-text { display: flex; flex-direction: column; gap: 2px; }
.au-avatar-title { font-size: .9375rem; font-weight: 600; }
.au-avatar-action { font-size: .875rem; font-weight: 600; color: var(--accent); }

/* ---------- малки екрани: при регистрация без картинка ---------- */
@media (max-width: 899px) {
  .au-shell {
    gap: 0;
}
  /* .au-shell[data-view="register"] .au-hero-media { display: none; } */
.form-box{    background: #fff;
    padding: 17px 17px 110px 17px;
    margin: 0px auto 0 auto;
    border-top-left-radius: 20px;
        border-top-right-radius: 20px;
    box-shadow: 0 -10px 10px rgb(0 0 0 / 14%);}
  .au-page {
    padding: 0;
}
  .au-hero-title { padding: 20px 20px 0 20px;}
.au-hero-sub {
    padding: 0 20px;
}
}

/* ---------- десктоп: две колони ---------- */
@media (min-width: 900px) {
  .au-page { padding: 40px 0 72px; }


  .au-shell {
    grid-template-columns: minmax(0, 1fr) 460px;
    gap: 72px;
    align-items: center;
  }
  .au-hero, .au-card { max-width: none; margin: 0; }

  .au-hero-title { font-size: 3.5rem; padding: 0 20px;}
  .au-hero-sub {         font-size: 16px; padding: 0 20px;}
  .au-hero-media { margin-top: 32px; 
    /* aspect-ratio: 16 / 10;  */
    border-radius: 22px; }

  .au-card {
    padding: 40px;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: #fff;
  }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}

.scrollTop {
    position: fixed;
    right: 10px;
    border-radius: 3px;
    z-index: 99999;
    font-weight: 600;
    bottom: 110px;
    background-color: rgba(0, 0, 0, .5);
    padding: 5px 7px;
    opacity: 0;
    transition: all .4s ease-in-out 0s;
}
.scrollTop a {
    font-size: 16px;
    text-decoration: none;
    color: #fff;
}