:root {
  --ninght-primary: #0058be;
  --ninght-primary-shadow: rgba(0, 88, 190, 0.2);
  --ninght-surface: #f8f9fa;
  --ninght-on-surface: #191c1d;
  --ninght-on-surface-variant: #424754;
  --ninght-outline: #727785;
  --ninght-outline-variant: #c2c6d6;
  --ninght-error: #ba1a1a;
  --ninght-error-container: #ffdad6;
  --ninght-font-body: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ninght-font-label: Geist, Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

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

body.ninght-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  background: var(--ninght-surface);
  color: var(--ninght-on-surface);
  font-family: var(--ninght-font-body);
}

.ninght-ambient-glow {
  position: fixed;
  top: 50%;
  left: 50%;
  z-index: -1;
  width: 800px;
  height: 800px;
  pointer-events: none;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(59, 130, 246, 0.03) 0%, rgba(255, 255, 255, 0) 70%);
}

.ninght-decoration {
  position: absolute;
  top: 0;
  right: 0;
  z-index: -1;
  width: 50%;
  height: 100vh;
  overflow: hidden;
  pointer-events: none;
}

.ninght-floating-decoration {
  position: absolute;
  top: 10%;
  right: -5%;
  color: var(--ninght-primary);
  opacity: 0.03;
  animation: ninght-float 10s ease-in-out infinite;
}

@keyframes ninght-float {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }

  50% {
    transform: translateY(-20px) rotate(2deg);
  }
}

.ninght-topbar,
.ninght-footer {
  width: 100%;
  max-width: 1200px;
  margin-right: auto;
  margin-left: auto;
  padding-right: 48px;
  padding-left: 48px;
}

.ninght-topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  padding-bottom: 24px;
  background: transparent;
}

.ninght-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ninght-on-surface);
  font-size: 32px;
  font-weight: 700;
  line-height: 40px;
  text-decoration: none;
}

.ninght-brand-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.ninght-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.ninght-nav a,
.ninght-footer a {
  color: var(--ninght-on-surface-variant);
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease, background-color 0.2s ease;
}

.ninght-nav a:hover,
.ninght-footer a:hover {
  color: var(--ninght-primary);
}

.ninght-outline-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 8px 20px;
  border: 1px solid var(--ninght-primary);
  border-radius: 12px;
  color: var(--ninght-primary);
  font-family: var(--ninght-font-label);
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
}

.ninght-outline-button:not(.ninght-disabled):hover {
  background: var(--ninght-primary);
  color: #fff;
}

.ninght-disabled {
  opacity: 0.75;
}

.ninght-menu-button {
  display: none;
  width: 36px;
  height: 36px;
  padding: 8px;
  border: 0;
  background: transparent;
}

.ninght-menu-button span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px 0;
  border-radius: 9999px;
  background: var(--ninght-on-surface);
}

.ninght-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 96px 16px 48px;
}

.ninght-glass-card {
  width: 100%;
  max-width: 440px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px;
  border: 1px solid var(--ninght-outline-variant);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 40px 60px -15px rgba(59, 130, 246, 0.05);
}

.ninght-card-heading {
  margin-bottom: 32px;
  text-align: center;
}

.ninght-card-heading h1 {
  margin: 0 0 8px;
  color: var(--ninght-on-surface);
  font-size: 32px;
  font-weight: 600;
  line-height: 40px;
}

.ninght-card-heading p {
  margin: 0;
  color: rgba(66, 71, 84, 0.8);
  font-size: 16px;
  line-height: 24px;
}

.ninght-alert {
  width: 100%;
  margin: 0 0 18px;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 20px;
}

.ninght-alert-error {
  background: var(--ninght-error-container);
  color: var(--ninght-error);
}

.ninght-alert-success,
.ninght-alert-info,
.ninght-alert-warning {
  background: rgba(216, 226, 255, 0.9);
  color: #004395;
}

.ninght-form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.ninght-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ninght-field label,
.ninght-label-row label {
  margin-left: 4px;
  color: var(--ninght-outline);
  font-family: var(--ninght-font-label);
  font-size: 12px;
  font-weight: 600;
  line-height: 16px;
  letter-spacing: 0.05em;
}

.ninght-label-row {
  display: flex;
  align-items: end;
  justify-content: space-between;
}

.ninght-link-small {
  color: var(--ninght-primary);
  font-family: var(--ninght-font-label);
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
}

.ninght-link-small:hover {
  text-decoration: underline;
}

.ninght-input-wrap {
  position: relative;
}

.ninght-input-icon {
  position: absolute;
  top: 50%;
  left: 12px;
  width: 20px;
  height: 20px;
  transform: translateY(-50%);
  color: var(--ninght-outline);
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
  pointer-events: none;
}

.ninght-input-wrap input[type="text"],
.ninght-input-wrap input[type="email"],
.ninght-input-wrap input[type="password"] {
  width: 100%;
  min-height: 48px;
  padding: 12px 48px 12px 40px;
  border: 1px solid var(--ninght-outline-variant);
  border-radius: 12px;
  outline: none;
  background: #fff;
  color: var(--ninght-on-surface);
  font-size: 16px;
  line-height: 24px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.ninght-input-wrap input[type="text"]:focus,
.ninght-input-wrap input[type="email"]:focus,
.ninght-input-wrap input[type="password"]:focus {
  border-color: var(--ninght-primary);
  box-shadow: 0 0 0 4px rgba(0, 88, 190, 0.1);
}

.ninght-input-wrap input::placeholder {
  color: rgba(114, 119, 133, 0.75);
}

.ninght-password-toggle {
  position: absolute;
  top: 50%;
  right: 12px;
  width: 24px;
  height: 24px;
  padding: 2px;
  border: 0;
  color: var(--ninght-outline);
  background: transparent;
  transform: translateY(-50%);
  cursor: pointer;
}

.ninght-password-toggle:hover {
  color: var(--ninght-on-surface);
}

.ninght-password-toggle svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.ninght-remember {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 4px;
  color: var(--ninght-on-surface-variant);
  font-family: var(--ninght-font-label);
  font-size: 13px;
  font-weight: 500;
  line-height: 20px;
  cursor: pointer;
}

.ninght-remember input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--ninght-primary);
}

.ninght-submit {
  width: 100%;
  min-height: 52px;
  border: 0;
  border-radius: 12px;
  background: var(--ninght-primary);
  color: #fff;
  box-shadow: 0 10px 15px -3px var(--ninght-primary-shadow);
  font-family: var(--ninght-font-label);
  font-size: 16px;
  font-weight: 500;
  line-height: 20px;
  cursor: pointer;
  transition: box-shadow 0.2s ease;
}

.ninght-submit:hover {
  box-shadow: 0 14px 20px -4px rgba(0, 88, 190, 0.3);
}

.ninght-divider {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 32px 0;
}

.ninght-divider span {
  flex: 1;
  height: 1px;
  background: rgba(194, 198, 214, 0.3);
}

.ninght-divider em {
  color: rgba(114, 119, 133, 0.6);
  font-family: var(--ninght-font-label);
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
  line-height: 16px;
  letter-spacing: 0.05em;
  white-space: nowrap;
}

.ninght-social-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.ninght-social-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 48px;
  padding: 12px;
  border: 1px solid var(--ninght-outline-variant);
  border-radius: 12px;
  color: var(--ninght-on-surface-variant);
  font-family: var(--ninght-font-label);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.ninght-social-button:hover {
  background: #fff;
}

.ninght-social-button.ninght-disabled {
  pointer-events: none;
}

.ninght-social-mark {
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: #fff;
  color: var(--ninght-primary);
  font-size: 12px;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(194, 198, 214, 0.8);
}

.ninght-github-mark {
  width: 20px;
  height: 20px;
  color: var(--ninght-on-surface);
  opacity: 0.8;
}

.ninght-signup {
  margin: 32px 0 0;
  color: rgba(66, 71, 84, 0.6);
  font-size: 13px;
  line-height: 20px;
}

.ninght-signup a {
  color: var(--ninght-primary);
  font-weight: 500;
  text-decoration: none;
}

.ninght-disabled-link {
  color: var(--ninght-primary);
  font-weight: 500;
}

.ninght-signup a:hover {
  text-decoration: underline;
}

.ninght-register-card {
  max-width: 560px;
}

.ninght-consent-card {
  position: relative;
  max-width: 560px;
  align-items: stretch;
}

.ninght-locale-switch {
  align-self: flex-end;
  display: inline-flex;
  gap: 4px;
  margin: -16px -16px 16px 0;
  padding: 4px;
  border: 1px solid rgba(194, 198, 214, 0.65);
  border-radius: 10px;
  background: rgba(248, 249, 250, 0.85);
}

.ninght-locale-switch a {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: 7px;
  color: var(--ninght-on-surface-variant);
  font-size: 12px;
  font-weight: 600;
  line-height: 20px;
  text-decoration: none;
}

.ninght-locale-switch a:hover,
.ninght-locale-switch a.is-active {
  background: #fff;
  color: var(--ninght-primary);
  box-shadow: 0 1px 4px rgba(25, 28, 29, 0.08);
}

.ninght-consent-symbol {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  margin-bottom: 20px;
  border-radius: 16px;
  background: rgba(216, 226, 255, 0.8);
  color: var(--ninght-primary);
}

.ninght-consent-symbol svg {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.ninght-consent-heading {
  margin-bottom: 24px;
}

.ninght-consent-eyebrow {
  margin-bottom: 6px !important;
  color: var(--ninght-primary) !important;
  font-family: var(--ninght-font-label);
  font-size: 12px !important;
  font-weight: 700;
  line-height: 16px !important;
}

.ninght-consent-permissions {
  width: 100%;
  padding: 20px;
  border: 1px solid rgba(194, 198, 214, 0.55);
  border-radius: 16px;
  background: rgba(248, 249, 250, 0.82);
}

.ninght-consent-permissions h2 {
  margin: 0 0 14px;
  color: var(--ninght-on-surface);
  font-size: 14px;
  font-weight: 650;
  line-height: 20px;
}

.ninght-consent-permissions ul {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ninght-consent-permissions li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--ninght-on-surface-variant);
  font-size: 14px;
  line-height: 20px;
}

.ninght-consent-permissions li strong {
  font-weight: 600;
}

.ninght-permission-check {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: rgba(0, 88, 190, 0.1);
  color: var(--ninght-primary);
}

.ninght-permission-check svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.2;
}

.ninght-consent-form {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  margin-top: 24px;
}

.ninght-secondary-button {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--ninght-outline-variant);
  border-radius: 12px;
  background: #fff;
  color: var(--ninght-on-surface-variant);
  font-family: var(--ninght-font-label);
  font-size: 16px;
  font-weight: 500;
  line-height: 20px;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.ninght-secondary-button:hover {
  border-color: var(--ninght-primary);
  color: var(--ninght-primary);
}

.ninght-consent-note,
.ninght-consent-legal {
  margin: 16px 0 0;
  color: rgba(66, 71, 84, 0.7);
  font-size: 12px;
  line-height: 18px;
  text-align: center;
}

.ninght-consent-legal a {
  color: var(--ninght-primary);
  font-weight: 600;
  text-decoration: none;
}

.ninght-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.ninght-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  padding-top: 24px;
  padding-bottom: 24px;
  border-top: 1px solid rgba(194, 198, 214, 0.1);
  color: var(--ninght-on-surface-variant);
  font-family: var(--ninght-font-label);
  font-size: 12px;
  font-weight: 600;
  line-height: 16px;
  letter-spacing: 0.05em;
}

.ninght-footer nav {
  display: flex;
  gap: 24px;
}

.ninght-footer a {
  opacity: 0.7;
}

.ninght-footer a:hover {
  opacity: 1;
}

@media (max-width: 767px) {
  .ninght-topbar,
  .ninght-footer {
    padding-right: 16px;
    padding-left: 16px;
  }

  .ninght-topbar {
    padding-top: 18px;
    padding-bottom: 18px;
  }

  .ninght-brand {
    font-size: 24px;
    line-height: 32px;
  }

  .ninght-nav {
    display: none;
  }

  .ninght-menu-button {
    display: block;
  }

  .ninght-main {
    padding-top: 88px;
  }

  .ninght-glass-card {
    padding: 32px 24px;
  }

  .ninght-card-heading h1 {
    font-size: 24px;
    line-height: 32px;
  }

  .ninght-social-grid {
    grid-template-columns: 1fr;
  }

  .ninght-form-grid {
    grid-template-columns: 1fr;
  }

  .ninght-consent-card {
    padding: 28px 20px;
  }

  .ninght-locale-switch {
    margin: -12px -8px 16px 0;
  }

  .ninght-consent-form {
    grid-template-columns: 1fr;
  }

  .ninght-footer {
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
  }
}
