* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  font-family: "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  color: var(--ink-900);
  background: var(--canvas) url("../img/background-new.jpeg") center / cover no-repeat;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: var(--scrim);
  pointer-events: none;
}

.navigation,
.content {
  display: none;
}

#main-content {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 40px 20px;
}

#kc-content {
  display: flex;
  width: 100%;
  justify-content: center;
}

#kc-content-wrapper {
  width: 100%;
  max-width: 480px;
  padding: 40px;
  background: var(--card-bg);
  backdrop-filter: blur(16px);
  border: 1px solid var(--card-border);
  border-radius: var(--r-xl);
  box-shadow: var(--sh-lg);
}

.logo-lang {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.image-logo {
  display: block;
  height: 30px;
  width: auto;
}

.select-language {
  min-width: 68px;
  height: 44px;
  padding: 0 28px 0 14px;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  color: var(--ink-700);
  background-color: var(--canvas-sunk);
  background-image: url("data:image/svg+xml;utf8,<svg fill='%23868e89' height='18' viewBox='0 0 24 24' width='18' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 6px center;
  border: 1px solid var(--border);
  border-radius: var(--r-full);
  cursor: pointer;
}

h1,
.h1 {
  margin: 0 0 6px;
  font-size: 30px;
  line-height: 36px;
  font-weight: 700;
  letter-spacing: -0.6px;
}

.form-subtitle {
  margin: 0 0 26px;
  font-size: 15px;
  line-height: 22px;
  color: var(--ink-500);
}

p {
  color: var(--ink-700);
}

a {
  color: var(--link);
  text-decoration: none;
  font-weight: 500;
  cursor: pointer;
}

a:hover {
  text-decoration: underline;
}

.form-forgot-wrapper {
  margin: -6px 0 16px;
  font-size: 14px;
  font-weight: 500;
}

.form-forgot-wrapper a {
  font-weight: 500;
}

.kc-info {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 14px;
}

.kc-info-container {
  letter-spacing: 0;
}

.last-login-info {
  flex-basis: 100%;
  margin: 0;
  font-size: 13px;
  line-height: 18px;
  color: var(--ink-400);
}

.last-login-info a {
  color: var(--link);
}

.css-alert {
  position: relative;
  z-index: 1;
}

@media (max-width: 560px) {
  #main-content {
    padding: 0;
    align-items: stretch;
  }

  #kc-content-wrapper {
    max-width: none;
    min-height: 100vh;
    min-height: 100dvh;
    padding: 32px 20px 40px;
    border: 0;
    border-radius: 0;
    background: var(--surface);
    backdrop-filter: none;
    box-shadow: none;
    display: flex;
    flex-direction: column;
  }

  .kc-info {
    margin-top: auto;
  }
}

.image-logo--dark {
  display: none;
}

[data-theme="dark"] .image-logo--light {
  display: none;
}

[data-theme="dark"] .image-logo--dark {
  display: block;
}

[data-theme="dark"] .captcha-image {
  background: #fff;
  padding: 4px;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--r-full);
  background: var(--canvas-sunk);
  color: var(--ink-700);
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.theme-toggle:hover {
  color: var(--ink-900);
  border-color: var(--border-strong);
}

.theme-toggle:focus-visible {
  outline: none;
  box-shadow: var(--ring);
}

.theme-toggle svg {
  display: block;
  width: 18px;
  height: 18px;
}

.theme-toggle .icon-moon {
  display: none;
}

[data-theme="dark"] .theme-toggle .icon-sun {
  display: none;
}

[data-theme="dark"] .theme-toggle .icon-moon {
  display: block;
}

.logo-lang-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.form-subtitle a {
  color: var(--link);
  font-weight: 500;
}

.form-subtitle span {
  font-weight: 500;
  color: var(--ink-900);
}
