:root {
  color-scheme: dark;
  font-family: "Noto Naskh Arabic", "Droid Arabic Naskh", Georgia, serif;
  color: #f8edf9;
  background: #231426;
  line-height: 1.65;
  --muted: #dbc3df;
  --link: #e5b9ed;
  --line: #7e6085;
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100dvh; }
button, input { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .7; }
:focus-visible { outline: 2px solid #b7caff; outline-offset: 3px; }
main {
  display: grid;
  justify-items: center;
  align-content: start;
  min-height: 100dvh;
  padding: 15px 12px 38px;
  background: radial-gradient(ellipse at 50% 0%, #2b1730, #211324 67%);
}

.screen-title {
  margin: 0 0 22px;
  color: #f3def5;
  font-size: 1.15rem;
  font-weight: 500;
  text-align: center;
  line-height: 1.6;
}
.screen-title:focus { outline: 0; }
.card {
  width: min(100%, 470px);
  min-width: 0;
  padding: 21px 17px 24px;
  border: 1px solid var(--line);
  border-radius: 23px;
  background: linear-gradient(145deg, #422b49, #352238);
}
p { margin: 0; }
.description { margin-bottom: 18px; color: var(--muted); }
form { display: grid; gap: 18px; }
label { font-size: 1.05rem; font-weight: 700; }
input {
  width: 100%;
  min-width: 0;
  height: 51px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #321f38;
  color: #fff;
  font: 500 1rem system-ui, sans-serif;
}
input[dir="ltr"] { text-align: left; }
input::placeholder { color: #e3cbe7; opacity: 1; }
#account { letter-spacing: .11em; }
.field { display: grid; gap: 6px; }
.field-hint { color: var(--muted); font-size: .805rem; line-height: 1.7; }
.pin-field { position: relative; }
.pin-field input { padding-left: 47px; }
.pin-toggle {
  position: absolute;
  display: grid;
  place-items: center;
  left: 5px;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #bdd0ff;
}
.eye {
  position: relative;
  width: 16px;
  height: 16px;
  border: 1.8px solid currentColor;
  border-radius: 12px 2px;
  transform: rotate(45deg);
}
.eye::before { content: ""; position: absolute; inset: 3px; border: 1.5px solid currentColor; border-radius: 50%; }
.is-visible .eye::after { content: ""; position: absolute; inset: 5px -4px auto; height: 2px; background: currentColor; }
.primary, .secondary {
  min-height: 51px;
  padding: 7px 12px;
  border-radius: 12px;
  font-size: 1.2rem;
  font-weight: 700;
}
.primary { border: 1px solid #c666f1; background: linear-gradient(110deg, #9422e6, #a02be4); color: #fff; }
.primary:hover { background: #8c20d7; }
.secondary { border: 1px solid var(--line); background: #321f38; color: var(--link); }
.actions { display: grid; gap: 12px; margin-top: 16px; }
.message { color: #ffd0cf; overflow-wrap: anywhere; }
.message:empty { display: none; }
.account-number { display: block; background: #321f38; padding: 8px; font-weight: 700; text-align: center; border-radius: 8px; margin-bottom: 14px; }
.codes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 5px 12px; font-family: monospace; margin: 8px 0 20px; }
.loading { color: var(--muted); text-align: center; }
.text-action {
  display: inline-grid;
  place-items: center;
  min-height: 44px;
  padding: 2px 9px;
  border: 0;
  background: transparent;
  color: var(--link);
  font-size: .99rem;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 5px;
  text-align: center;
}
.text-action:hover { color: #fff; }
.login-links { display: grid; justify-items: center; gap: 15px; margin-top: 15px; }
.support-row { width: 100%; border-top: 1px solid #604763; text-align: center; padding-top: 12px; }
.setup-link { margin-top: 20px; }
[data-screen="login"] form { gap: 24px; }
[data-screen="login"] .primary { margin-top: 2px; }
[data-screen="login"] .text-action { max-width: 100%; }
[data-screen="login"] #forgot-both { max-width: 280px; }

@media (min-width: 550px) {
  main { padding-top: 30px; }
  .card { padding-inline: 24px; }
}

select {
  width: 100%;
  min-width: 0;
  min-height: 51px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #321f38;
  color: #fff;
  font: inherit;
}
.codes { font-size: .87rem; overflow-wrap: anywhere; }
#store-name:not(:empty) { margin-bottom: 12px; text-align: center; }

.language-bar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  width: min(100%, 518px);
  margin-inline: auto;
  padding: 10px 12px 0;
}
.language-field {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: .9rem;
}
.language-field select {
  width: 9rem;
  min-height: 44px;
  padding-block: 5px;
  border-radius: 9px;
  color: #f8edf9;
}

html[dir="ltr"] { font-family: system-ui, sans-serif; }
