/* Nordic telecom–inspired login (generic; use your own logo) */

:root {
  --purple: #990ae3;
  --purple-hover: #7b08b8;
  --purple-soft: rgba(153, 10, 227, 0.12);
  --text: #222222;
  --text-muted: #5c5c5c;
  --text-subtle: #767676;
  --border: #d0d0d0;
  --border-focus: var(--purple);
  --page-bg: #f5f5f7;
  --card-bg: #ffffff;
  --radius-card: 12px;
  --radius-input: 6px;
  --radius-btn: 999px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--text);
  background: var(--page-bg);
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

.topbar {
  background: #fff;
  color: var(--text);
  border-bottom: 1px solid #e8e8e8;
}

.topbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  color: inherit;
  text-decoration: none;
  line-height: 0;
}

.brand-logo {
  display: block;
  height: var(--brand-logo-h, 2rem);
  width: auto;
  max-width: min(200px, 50vw);
  object-fit: contain;
  object-position: left center;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.footer-logo {
  display: block;
  height: 1.125rem;
  width: auto;
  max-width: 120px;
  object-fit: contain;
  object-position: left center;
  opacity: 0.85;
}

.topbar-nav {
  display: flex;
  gap: 1.5rem;
  font-size: 0.9375rem;
}

.topbar-nav a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
}

.topbar-nav a:hover {
  color: var(--purple);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.main {
  flex: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 2.5rem 1.25rem 3rem;
}

.login-shell {
  width: 100%;
  max-width: 420px;
}

.login-eyebrow {
  margin: 0 0 0.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-subtle);
}

.login-card {
  background: var(--card-bg);
  border-radius: var(--radius-card);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
  border: 1px solid #ebebeb;
  padding: 2rem 1.75rem 1.75rem;
}

.login-title {
  margin: 0 0 0.5rem;
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--text);
  letter-spacing: -0.02em;
}

.login-lead {
  margin: 0 0 1.75rem;
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.login-form .field {
  margin-bottom: 1.25rem;
}

.login-form label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.login-form input[type="text"],
.login-form input[type="password"] {
  width: 100%;
  padding: 0.875rem 1rem;
  font-size: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-input);
  font-family: inherit;
  background: #fff;
  color: var(--text);
  min-height: 3rem;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.login-form input::placeholder {
  color: #9a9a9a;
}

.login-form input:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--purple-soft);
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
}

.remember {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
}

.remember input {
  width: 1.125rem;
  height: 1.125rem;
  accent-color: var(--purple);
}

.link {
  color: var(--purple);
  text-decoration: none;
  font-weight: 600;
}

.link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.btn-primary {
  width: 100%;
  appearance: none;
  border: none;
  border-radius: var(--radius-btn);
  padding: 0.9rem 1.25rem;
  font-size: 1rem;
  font-weight: 700;
  font-family: inherit;
  color: #fff;
  background: var(--purple);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3rem;
  transition: background 0.15s, transform 0.08s, box-shadow 0.15s;
}

.btn-primary:hover:not(:disabled) {
  background: var(--purple-hover);
  box-shadow: 0 4px 14px rgba(153, 10, 227, 0.35);
}

.btn-primary:active:not(:disabled) {
  transform: scale(0.99);
}

.btn-primary:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.btn-spinner {
  width: 1.1rem;
  height: 1.1rem;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.form-message {
  margin: 1rem 0 0;
  min-height: 1.25rem;
  font-size: 0.9rem;
}

.form-message.ok {
  color: #0d6832;
}

.form-message.err {
  color: #c62828;
}

.fine-print {
  margin: 1.5rem 0 0;
  font-size: 0.75rem;
  color: var(--text-subtle);
  line-height: 1.55;
  text-align: center;
}

.footer {
  margin-top: auto;
  border-top: 1px solid #e8e8e8;
  background: #fff;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: center;
  justify-content: center;
  font-size: 0.8125rem;
  color: var(--text-subtle);
}

.footer-inner a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
}

.footer-inner a:hover {
  color: var(--purple);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.thank-you-card {
  text-align: center;
  padding-top: 2rem;
  padding-bottom: 2rem;
}

.thank-you-icon {
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 auto 1.25rem;
  border-radius: 50%;
  background: var(--purple-soft);
  color: var(--purple);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 3.5rem;
}

.thank-you-title {
  margin-bottom: 0.75rem;
}

.thank-you-text {
  margin: 0 0 1.75rem;
  font-size: 1.0625rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.thank-you-btn {
  text-decoration: none;
  display: inline-flex;
  max-width: 100%;
}

@media (max-width: 520px) {
  .topbar-nav {
    display: none;
  }

  .login-card {
    padding: 1.5rem 1.25rem;
    border-radius: 10px;
  }

  .login-title {
    font-size: 1.5rem;
  }
}
