:root {
  --bg: #0b0b0f;
  --surface: #131318;
  --surface-raised: #1a1a21;
  --border: #26262e;
  --text: #f2f2f7;
  --text-muted: #8b8b98;
  --accent: #6c8cff;
  --accent-hover: #84a0ff;
  --success: #34c759;
  --success-hover: #3fd566;
  --error: #ff5c5c;
  --focus: #6c8cff;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.gate {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.card {
  width: 100%;
  max-width: 380px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.card__header {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.card__title {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.card__subtitle {
  font-size: 0.875rem;
  color: var(--text-muted);
}

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

.field__label {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
}

.field__input {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  background: var(--surface-raised);
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
  border: 1px solid var(--border);
  border-radius: 10px;
  outline: none;
}

.field__input::placeholder {
  color: var(--text-muted);
}

.field__input:focus-visible {
  border-color: var(--focus);
  box-shadow: 0 0 0 3px rgba(108, 140, 255, 0.18);
}

.field__hint {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.error {
  font-size: 0.875rem;
  color: var(--error);
  line-height: 1.4;
}

.error[hidden] {
  display: none;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 48px;
  padding: 0 16px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  color: #fff;
  background: var(--accent);
  border: 1px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  text-decoration: none;
  outline: none;
}

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

.button:focus-visible {
  box-shadow: 0 0 0 3px rgba(108, 140, 255, 0.35);
}

.button:disabled {
  opacity: 0.55;
  cursor: default;
}

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

.button--success {
  background: var(--success);
}

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

.button--success:focus-visible {
  box-shadow: 0 0 0 3px rgba(52, 199, 89, 0.35);
}

.button[hidden] {
  display: none;
}

@media (max-width: 480px) {
  .card {
    padding: 24px;
    border-radius: 12px;
  }
}
