@font-face {
  font-family: 'Gilroy';
  font-style: normal;
  font-weight: 400;
  src: url('/static/Gilroy-Regular.woff') format('woff');
}

@font-face {
  font-family: 'Gilroy';
  font-style: normal;
  font-weight: 700;
  src: url('/static/Gilroy-Bold.woff') format('woff');
}

:root {
  --brand-ink: #1f2a37;
  --brand-muted: #5f6b77;
  --brand-accent: #3c3996;
  --brand-accent-strong: #4b57b8;
  --surface: #ffffff;
  --surface-border: #e6eaf0;
  --surface-soft: #f8fafc;
}

body {
  background: radial-gradient(1100px 520px at 10% -15%, #eef2ff 0%, transparent 60%),
    radial-gradient(900px 520px at 100% 10%, #e9f4ff 0%, transparent 55%), #f4f6fb;
  font-size: 16px;
  margin: 0;
  line-height: 1.4;
  font-family: 'Gilroy';
  color: var(--brand-ink);
  min-height: 100vh;
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle at 1px 1px, rgba(60, 57, 150, 0.06) 1px, transparent 0);
  background-size: 36px 36px;
  opacity: 0.35;
  pointer-events: none;
}

#container {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 48px 20px;
  box-sizing: border-box;
  position: relative;
  z-index: 1;
}

/* Loading spinner */
.lds-dual-ring {
  margin-bottom: 23px;
  display: inline-block;
  width: 30px;
  height: 30px;
  position: absolute;
  margin-right: 35px;
}

.lds-dual-ring:after {
  content: ' ';
  display: block;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid rgb(148, 148, 148);
  border-color: rgb(148, 148, 148) transparent rgb(148, 148, 148) transparent;
  animation: lds-dual-ring 1.2s linear infinite;
}

@keyframes lds-dual-ring {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Container styles */
.login-options-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: min(520px, 100%);
  padding: 52px 44px 44px;
  border-radius: 16px;
  visibility: hidden;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.16);
  background-color: var(--surface);
  border: 1px solid var(--surface-border);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.login-options-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: linear-gradient(90deg, var(--brand-accent), #545fcb);
}

.login-welcome-message {
  margin-top: 32px;
  text-align: left;
  max-width: 100%;
}

.login-title {
  font-weight: 700;
  font-size: 24px;
  color: var(--brand-ink);
  margin-bottom: 8px;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.login-subtitle {
  font-weight: 400;
  font-size: 15px;
  color: var(--brand-muted);
  line-height: 1.6;
  max-width: 100%;
}




.login-options-container > .login-options-header {
  width: 100%;
  border-top-right-radius: 8px;
  border-top-left-radius: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.login-options-container > .login-options-header > .login-options-logo {
  width: 168px;
}

.login-button-container {
  box-sizing: border-box;
  width: 100%;
  display: flex;
  flex-direction: column;
  row-gap: 18px;
  align-items: stretch;
  margin-top: 8px;
}

/* Button styles */
.primary-login-button {
  display: flex;
  padding: 8px 12px;
  justify-content: center;
  align-items: center;
  gap: 10px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--brand-accent), var(--brand-accent-strong));
  color: #fff;
  cursor: pointer;
  height: 50px;
  width: 100%;
  font-size: 16px;
  border: none;
  font-weight: 700;
  box-shadow: 0 10px 18px rgba(60, 57, 150, 0.22);
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.secondary-login-button {
  display: flex;
  padding: 8px 12px;
  justify-content: center;
  align-items: center;
  gap: 10px;
  border-radius: 8px;
  background: #fff;
  color: var(--brand-accent);
  cursor: pointer;
  height: 50px;
  width: 100%;
  font-size: 16px;
  border: 1px solid #d8dde5;
  font-weight: 700;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-login-button:hover {
  color: #fff;
  background-color: #4452b7;
  box-shadow: 0 12px 22px rgba(60, 57, 150, 0.28);
  transform: translateY(-1px);
}

.primary-login-button:active,
.secondary-login-button:active {
  transform: translateY(0);
  box-shadow: 0 6px 12px rgba(60, 57, 150, 0.16);
}

.secondary-login-button:hover {
  background-color: #f6f8fb;
  box-shadow: 0 8px 16px rgba(36, 36, 36, 0.12);
  transform: translateY(-1px);
}

button {
  font-family: inherit;
}

.email-input-container {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  position: relative;
}

.new-base-input {
  border: 1px solid #d8dde5;
  border-radius: 8px;
  padding: 0 16px;
  width: 100%;
  font-family: inherit;
  font-size: 16px;
  box-sizing: border-box;
  margin-bottom: 15px;
  background-color: var(--surface-soft);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.new-base-input::placeholder {
  color: #94a3b8;
}

.new-base-input.error {
  border: 1px solid #bf3636 !important;
}

.new-base-input:focus {
  outline: none;
  border: 1px solid var(--brand-accent);
  box-shadow: 0 0 0 4px rgba(60, 57, 150, 0.16);
}

.new-base-input:focus.error {
  box-shadow: 0px 0px 4px 0px rgba(191, 54, 54, 0.72);
}

.new-base-input-medium {
  height: 50px;
}

.new-input-error {
  color: #bf3636;
  font-size: 12px;
  font-weight: bold;
  width: 100%;
  text-align: left;
  position: absolute;
  top: 46px;
  left: 0;
  display: none;
  line-height: 18px;
  align-items: center;
}

@media (max-width: 640px) {
  .login-options-container {
    padding: 36px 22px 32px;
    border-radius: 14px;
  }

  .login-welcome-message {
    margin-top: 24px;
  }

  .login-title {
    font-size: 22px;
  }

  .login-subtitle {
    font-size: 14px;
  }


  .primary-login-button,
  .secondary-login-button,
  .new-base-input {
    width: 100%;
  }
}

.new-input-error::before {
  content: '⚠️';
  margin-right: 4px;
}

/* URL Error Message Styles */
.url-error-container {
  width: 100%;
  display: none;
  margin-bottom: 16px;
}

.url-error-message {
  padding: 12px 16px;
  background-color: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  margin: 0 auto;
  max-width: 400px;
  box-sizing: border-box;
  text-align: center;
}

.url-error-text {
  color: #dc2626;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
}
