:root {
  color-scheme: light dark;
  font-family: "Segoe UI", system-ui, -apple-system, "Noto Sans Arabic", sans-serif;
  --brand: #0759b8;
  --brand-dark: #064a99;
  --ink: #182230;
  --muted: #5b6b7f;
  --line: #c7d2df;
  --error: #b00020;
  --surface: #ffffff;
  --page: #f4f7fb;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  background: var(--page);
  color: var(--ink);
}

.card {
  width: min(100%, 28rem);
  padding: 1.75rem 1.5rem;
  border-radius: 1rem;
  background: var(--surface);
  box-shadow: 0 10px 30px #001b4430;
}

.brand h1 {
  margin: 0 0 0.4rem;
  font-size: 1.4rem;
}

.subtitle {
  margin: 0 0 1.25rem;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

.status {
  margin: 0;
  color: var(--muted);
}

.status-error {
  color: var(--error);
  line-height: 1.6;
}

label {
  display: grid;
  gap: 0.4rem;
  margin: 1rem 0;
  font-weight: 600;
  font-size: 0.95rem;
}

input {
  font: inherit;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 0.6rem;
  background: var(--surface);
  color: inherit;
  width: 100%;
}

input:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 1px;
}

.check {
  display: flex;
  align-items: center;
  font-weight: 400;
}

.check input {
  width: auto;
  margin-inline-end: 0.5rem;
}

button {
  display: inline-block;
  width: 100%;
  border: 0;
  border-radius: 0.6rem;
  padding: 0.85rem 1rem;
  margin-top: 0.5rem;
  background: var(--brand);
  color: #fff;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

button:hover:not(:disabled) {
  background: var(--brand-dark);
}

button:disabled {
  opacity: 0.6;
  cursor: progress;
}

.error {
  color: var(--error);
  min-height: 1.3rem;
  line-height: 1.5;
}

.success {
  text-align: center;
  line-height: 1.7;
}

.success-icon {
  width: 3rem;
  height: 3rem;
  margin: 0 auto 0.75rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #e3f2e6;
  color: #1b7f3b;
  font-size: 1.6rem;
}

.success h2 {
  margin: 0 0 0.5rem;
  font-size: 1.2rem;
}

.summary {
  color: var(--muted);
  font-size: 0.9rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e8eef6;
    --muted: #9fb0c3;
    --line: #3a4757;
    --surface: #1b2431;
    --page: #10161f;
  }

  .success-icon {
    background: #16311f;
    color: #6fe39a;
  }
}
