/* ========================================
   KYOKORA AUTHENTICATION
======================================== */

:root {
  color-scheme: dark;

  --bg: #080f1e;
  --bg-soft: #0b1425;
  --surface: #0d192c;
  --surface-hover: #12233b;

  --blue: #79adff;
  --blue-bright: #a4c9ff;

  --text: #edf3ff;
  --muted: #a0aec4;
  --dim: #697b96;

  --border: rgba(155, 187, 231, 0.14);
  --border-focus: rgba(121, 173, 255, 0.75);
}


/* ========================================
   GLOBAL
======================================== */

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;

  background:
    radial-gradient(
      ellipse at 50% 0%,
      rgba(48, 91, 153, 0.16),
      transparent 55%
    ),
    var(--bg);

  color: var(--text);
  font-family: "Inter", sans-serif;
  line-height: 1.6;

  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 2px solid var(--blue-bright);
  outline-offset: 4px;
}


/* ========================================
   PAGE LAYOUT
======================================== */

.auth-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  width: min(100% - 32px, 460px);
  min-height: 100vh;
  min-height: 100svh;

  margin: 0 auto;
  padding: 38px 0 24px;
}


/* ========================================
   BRAND
======================================== */

.brand {
  display: flex;
  flex-direction: column;
  align-items: center;

  margin-bottom: 30px;

  text-align: center;
}

.brand-name {
  color: var(--text);

  font-family: "Oxanium", sans-serif;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: 5px;
}


/* ========================================
   AUTHENTICATION CARD
======================================== */

.auth-card {
  width: 100%;
  padding: 38px;

  border: 1px solid var(--border);
  border-radius: 12px;

  background: linear-gradient(
    145deg,
    rgba(16, 31, 52, 0.97),
    rgba(10, 20, 36, 0.98)
  );

  box-shadow:
    0 20px 70px rgba(0, 0, 0, 0.2),
    0 0 35px rgba(121, 173, 255, 0.035);
}


/* ========================================
   HEADING
======================================== */

.auth-heading {
  margin-bottom: 30px;
}

.auth-heading h1 {
  margin: 0;

  color: var(--blue);

  font-family: "Oxanium", sans-serif;
  font-size: 34px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.5px;
}

.auth-description {
  margin: 12px 0 0;

  color: var(--muted);
  font-size: 13px;
  line-height: 1.8;
}


/* ========================================
   FORM
======================================== */

#login-form {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.form-field label {
  color: #d8e3f5;
  font-size: 12px;
  font-weight: 600;
}


/* ========================================
   INPUTS
======================================== */

.form-field input {
  width: 100%;
  min-height: 49px;
  padding: 12px 14px;

  border: 1px solid rgba(155, 187, 231, 0.2);
  border-radius: 6px;

  background: var(--bg-soft);
  color: var(--text);

  font-size: 13px;

  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    box-shadow 0.2s ease;
}

.form-field input::placeholder {
  color: var(--dim);
  opacity: 1;
}

.form-field input:hover {
  border-color: rgba(121, 173, 255, 0.4);
}

.form-field input:focus {
  border-color: var(--border-focus);
  background: #0d1a2e;

  outline: none;

  box-shadow: 0 0 0 3px rgba(121, 173, 255, 0.08);
}


/* ========================================
   PASSWORD FIELD
======================================== */

.password-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.password-control {
  position: relative;

  display: flex;
  align-items: center;
}

.password-control input {
  padding-right: 48px;
}

.password-toggle {
  position: absolute;
  right: 7px;

  display: grid;
  place-items: center;

  width: 36px;
  height: 36px;
  padding: 0;

  border: 0;
  border-radius: 5px;

  background: transparent;
  color: var(--dim);

  cursor: pointer;

  transition:
    color 0.2s ease,
    background 0.2s ease;
}

.password-toggle:hover {
  background: rgba(121, 173, 255, 0.08);
  color: var(--blue-bright);
}

.password-toggle:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 1px;
}

.eye-icon {
  display: block;

  width: 19px;
  height: 19px;
}


/* ========================================
   TEXT LINKS
======================================== */

.text-link {
  color: var(--blue);

  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;

  transition: color 0.2s ease;
}

.text-link:hover {
  color: var(--blue-bright);
}


/* ========================================
   LOGIN BUTTON
======================================== */

.auth-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;

  width: 100%;
  min-height: 49px;
  padding: 13px 17px;

  border: 1px solid var(--blue);
  border-radius: 6px;

  background: var(--blue);
  color: #080f1e;

  font-family: "Oxanium", sans-serif;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1px;

  cursor: pointer;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.auth-button:hover {
  border-color: var(--blue-bright);
  background: var(--blue-bright);

  box-shadow: 0 0 25px rgba(121, 173, 255, 0.18);
}

.auth-button:active {
  transform: translateY(1px);
}

.button-arrow {
  font-family: "Inter", sans-serif;
  font-size: 19px;
  line-height: 1;
}


/* ========================================
   FORM MESSAGE
======================================== */

.form-message {
  display: none;

  margin: -8px 0 0;

  color: #ff6b75;
  font-size: 12px;

  overflow-wrap: anywhere;
}

.form-message:not(:empty) {
  display: block;
}

/* ========================================
   REGISTER LINK
======================================== */

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;

  margin: 28px 0 18px;
}

.auth-divider span {
  flex: 1;
  height: 1px;

  background: var(--border);
}

.auth-divider p {
  margin: 0;

  color: var(--dim);

  font-family: "Oxanium", sans-serif;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 1px;
  white-space: nowrap;
}

.register-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;

  min-height: 46px;
  padding: 12px 14px;

  border: 1px solid rgba(155, 187, 231, 0.2);
  border-radius: 6px;

  background: rgba(121, 173, 255, 0.025);
  color: #d8e3f5;

  font-size: 12px;
  font-weight: 600;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease;
}

.register-link span {
  color: var(--blue);
  font-size: 16px;
}

.register-link:hover {
  border-color: rgba(121, 173, 255, 0.5);
  background: rgba(121, 173, 255, 0.07);
  color: white;
}


/* ========================================
   FOOTER
======================================== */

.auth-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;

  width: 100%;
  margin-top: 24px;
}

.auth-footer a {
  color: var(--muted);
  font-size: 10px;

  transition: color 0.2s ease;
}

.auth-footer a:hover {
  color: var(--blue-bright);
}

.auth-footer p {
  margin: 0;

  color: var(--dim);

  font-family: "Oxanium", sans-serif;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 1px;
}


/* ========================================
   MOBILE
======================================== */

@media (max-width: 480px) {
  .auth-page {
    width: min(100% - 28px, 400px);
    padding: 28px 0 20px;
  }

  .brand {
    margin-bottom: 24px;
  }

  .brand-name {
    font-size: 25px;
  }

  .auth-card {
    padding: 27px 22px;
    border-radius: 10px;
  }

  .auth-heading {
    margin-bottom: 26px;
  }

  #login-form {
    gap: 20px;
  }

  .auth-footer {
    gap: 10px;
  }

  .auth-footer a,
  .auth-footer p {
    font-size: 9px;
  }
}


/* ========================================
   REDUCED MOTION
======================================== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* ACTION ICONS */

.action-icon {
  display: block;
  flex-shrink: 0;
  width: 18px;
  height: 18px;
}

.register-link .action-icon {
  color: var(--blue);
  transition: transform 0.2s ease;
}

.register-link:hover .action-icon {
  transform: translateX(2px);
}