:root {
  --bg: #0f172a;
  --bg-soft: #111c33;
  --card: rgba(255, 255, 255, 0.94);
  --card-border: rgba(148, 163, 184, 0.28);
  --text: #0f172a;
  --muted: #64748b;
  --muted-dark: #cbd5e1;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --danger: #dc2626;
  --warning: #f59e0b;
  --success: #16a34a;
  --input: #e2e8f0;
  --shadow: 0 24px 80px rgba(15, 23, 42, 0.38);
  --radius: 28px;
  --radius-sm: 14px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(circle at 16% 12%, rgba(59, 130, 246, 0.28), transparent 32%),
    radial-gradient(circle at 84% 28%, rgba(14, 165, 233, 0.22), transparent 30%),
    linear-gradient(135deg, #0f172a 0%, #111827 52%, #020617 100%);
}

button,
input {
  font: inherit;
}

a {
  color: inherit;
}

.page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(400px, 0.85fr);
}

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 48px;
  color: #fff;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 32px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 36px;
  pointer-events: none;
}

.brand {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.brand__logo {
  width: 52px;
  height: 52px;
}

.brand__name {
  font-weight: 800;
  letter-spacing: -0.02em;
  font-size: 20px;
}

.brand__domain {
  margin-top: 3px;
  color: var(--muted-dark);
  font-size: 14px;
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: 780px;
  margin: auto 0;
  padding: 64px 0;
}

.eyebrow {
  margin: 0 0 14px;
  color: #60a5fa;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(42px, 6vw, 74px);
  line-height: 0.95;
  letter-spacing: -0.07em;
}

.hero__text {
  max-width: 610px;
  margin: 26px 0 0;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.7;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 42px;
}

.feature-card {
  min-height: 154px;
  padding: 20px;
  border: 1px solid rgba(226, 232, 240, 0.13);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.44);
  backdrop-filter: blur(14px);
}

.feature-card__icon {
  display: inline-grid;
  width: 36px;
  height: 36px;
  margin-bottom: 18px;
  place-items: center;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.28);
  color: #bfdbfe;
  font-weight: 800;
}

.feature-card strong {
  display: block;
  color: #fff;
  font-size: 15px;
}

.feature-card p {
  margin: 8px 0 0;
  color: #cbd5e1;
  font-size: 13px;
  line-height: 1.55;
}

.hero__footer {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  color: #94a3b8;
  font-size: 14px;
}

.login-panel {
  display: grid;
  place-items: center;
  padding: 42px;
}

.login-card {
  width: min(100%, 500px);
  padding: 34px;
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.login-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.login-card h2 {
  margin: 0;
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.status-pill {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 8px 11px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--warning);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.status-pill[data-status="online"] .status-dot {
  background: var(--success);
  box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.14);
}

.status-pill[data-status="offline"] .status-dot {
  background: var(--danger);
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.14);
}

.notice {
  margin-top: 22px;
  padding: 13px 14px;
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-sm);
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 14px;
  line-height: 1.5;
}

.notice--hidden {
  display: none;
}

.form {
  margin-top: 28px;
}

.field {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
}

.field label,
.field__label-row label {
  color: #334155;
  font-size: 14px;
  font-weight: 800;
}

.field__label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.field input[type="email"],
.field input[type="password"],
.field input[type="text"] {
  width: 100%;
  min-height: 52px;
  padding: 0 15px;
  border: 1px solid var(--input);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--text);
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.field input:focus {
  border-color: rgba(37, 99, 235, 0.72);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.field input[aria-invalid="true"] {
  border-color: rgba(220, 38, 38, 0.76);
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.1);
}

.field__error {
  min-height: 17px;
  color: var(--danger);
  font-size: 12px;
  font-weight: 700;
}

.link-button {
  border: 0;
  background: transparent;
  color: var(--primary);
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
}

.form__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 6px 0 22px;
}

.checkbox {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #475569;
  cursor: pointer;
  font-size: 14px;
  font-weight: 650;
}

.checkbox input {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
}

.form__link {
  color: var(--primary);
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}

.form__link:hover,
.link-button:hover {
  text-decoration: underline;
}

.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 54px;
  border-radius: var(--radius-sm);
  font-weight: 850;
  text-decoration: none;
}

.primary-button {
  position: relative;
  border: 0;
  background: var(--primary);
  color: #fff;
  cursor: pointer;
  transition: background 0.18s ease, transform 0.18s ease;
}

.primary-button:hover {
  background: var(--primary-hover);
}

.primary-button:active {
  transform: translateY(1px);
}

.primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.78;
}

.button-loader {
  display: none;
  width: 19px;
  height: 19px;
  margin-left: 10px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.primary-button[data-loading="true"] .button-loader {
  display: inline-block;
}

.form-message {
  min-height: 24px;
  margin-top: 14px;
  color: var(--danger);
  font-size: 14px;
  font-weight: 750;
  line-height: 1.45;
}

.form-message[data-kind="success"] {
  color: var(--success);
}

.login-card__divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 22px 0;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 800;
}

.login-card__divider::before,
.login-card__divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e2e8f0;
}

.secondary-button {
  border: 1px solid #cbd5e1;
  background: #fff;
  color: #1e293b;
}

.secondary-button:hover {
  border-color: #93c5fd;
  color: var(--primary);
}

.security-note {
  margin-top: 24px;
  padding: 16px;
  border-radius: 18px;
  background: #f8fafc;
  color: #334155;
}

.security-note strong {
  display: block;
  font-size: 14px;
}

.security-note p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.security-note__domain {
  color: #0f172a;
  font-weight: 850;
  white-space: nowrap;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 1120px) {
  .page {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding: 34px 28px 10px;
  }

  .hero::before {
    display: none;
  }

  .hero__content {
    padding: 54px 0 34px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .hero__footer {
    display: none;
  }

  .login-panel {
    padding: 22px 22px 42px;
  }
}

@media (max-width: 560px) {
  .hero h1 {
    font-size: 42px;
  }

  .hero__text {
    font-size: 16px;
  }

  .login-card {
    padding: 24px;
    border-radius: 22px;
  }

  .login-card__header {
    flex-direction: column;
  }

  .form__row {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }
}
