[hidden].wx-methods,
.wx-login-panel[hidden],
.wx-login-panel [hidden],
#wx-password-panel[hidden],
.wx-dialog [hidden],
.wx-qr[hidden] {
  display: none !important;
}
#wx-password-panel {
  min-inline-size: 0;
  padding: 0;
  margin: 0;
  border: 0;
}
.wx-methods {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .25rem;
  margin-bottom: 1rem;
  padding: .25rem;
  border: 1px solid #dce5ef;
  border-radius: 12px;
  background: #f3f7fb;
}
.wx-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: .35rem;
  min-height: 44px;
  max-width: 100%;
  padding: .5rem .85rem;
  margin: 0;
  border: 1px solid #cbd8e6;
  border-radius: 8px;
  color: #204a7a;
  background: #fff;
  font: inherit;
  font-size: .875rem;
  font-weight: 600;
  line-height: 1.35;
  white-space: normal;
  text-align: center;
  cursor: pointer;
}
.wx-methods .wx-button {
  border-color: transparent;
  background: transparent;
}
.wx-methods .wx-button[aria-pressed="true"] {
  border-color: #b8d2ef;
  color: #1259ae;
  background: #fff;
}
.wx-button:hover:not(:disabled) {
  border-color: #7f9fc2;
}
.wx-button:focus-visible,
.wx-dialog :is(input, summary):focus-visible {
  outline: 2px solid #1767ce;
  outline-offset: 3px;
}
.wx-button:disabled {
  cursor: default;
  opacity: .56;
}
.wx-button.wx-primary {
  border-color: #1767ce;
  color: #fff;
  background: #1767ce;
}
.wx-button.wx-danger {
  border-color: #d3aaa5;
  color: #922c22;
}
.wx-login-panel {
  display: grid;
  justify-items: center;
  gap: .75rem;
  padding: 1rem 0;
}
.wx-login-actions {
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: .5rem;
  grid-row: 3;
  width: 100%;
}
.wx-qr {
  display: grid;
  justify-items: center;
  gap: .3rem;
  max-width: 100%;
  margin: .5rem auto;
}
.wx-qr img {
  display: block;
  width: min(196px, 100%);
  height: auto;
  background: #fff;
  border: 1px solid #dce5ef;
  border-radius: 8px;
}
.wx-countdown {
  color: #405671;
  font-variant-numeric: tabular-nums;
  font-size: .875rem;
}
.wx-status {
  margin: .65rem 0;
  color: #334d6a;
  font-size: .875rem;
  line-height: 1.55;
}
.wx-status:empty {
  display: none;
}
.wx-login-panel .wx-status {
  text-align: center;
}
.wx-session-notice[hidden],
.wx-existing-session :is(#wx-login-methods, #wx-login-panel, #wx-password-panel) {
  display: none !important;
}
.wx-session-notice {
  display: grid;
  justify-items: start;
  gap: .75rem;
  margin: 0 0 1rem;
  padding: 1rem;
  border: 1px solid #b9d5f5;
  border-inline-start: 4px solid #1767ce;
  border-radius: 12px;
  background: #eff6ff;
  color: #12294b;
}
.wx-session-notice strong {
  font-size: 1rem;
}
.wx-session-notice p {
  margin: .3rem 0 0;
  color: #334d6a;
  font-size: .875rem;
  font-variant-numeric: tabular-nums;
}
.wx-session-notice .wx-button {
  text-decoration: none;
}
.wx-dialog {
  box-sizing: border-box;
  width: min(470px, calc(100% - 2rem));
  max-width: none;
  max-height: calc(100vh - 2rem);
  max-height: calc(100dvh - 2rem);
  margin: auto;
  padding: clamp(1rem, 4vw, 1.5rem);
  border: 1px solid #dce5ef;
  border-radius: 16px;
  color: #12294b;
  background: #fff;
  box-shadow: 0 18px 56px #10274530;
  overflow: auto;
  overflow-wrap: anywhere;
}
.wx-dialog::backdrop {
  background: #12294b78;
}
.wx-dialog h2 {
  margin: 0 0 .75rem;
  font: inherit;
  font-size: 1.375rem;
  font-weight: 700;
  line-height: 1.3;
}
.wx-dialog h3,
.wx-dialog h4,
.wx-dialog p {
  margin: 0 0 .65rem;
}
.wx-dialog p {
  line-height: 1.55;
}
.wx-dialog .wx-field {
  display: grid;
  gap: .35rem;
  margin: .65rem 0;
  font-size: .875rem;
  font-weight: 600;
}
.wx-field input {
  box-sizing: border-box;
  width: 100%;
  min-height: 44px;
  padding: .5rem .65rem;
  border: 1px solid #bccada;
  border-radius: 8px;
  color: inherit;
  background: #fff;
  font-size: 1rem;
}
.wx-dialog .wx-actions {
  display: flex;
  justify-content: flex-end;
  align-items: stretch;
  gap: .55rem;
  margin-top: .75rem;
}
.wx-dialog .wx-actions > .wx-button,
.wx-login-actions > .wx-button {
  flex: 0 1 10rem;
  min-width: 0;
}
.wx-dialog button.wx-button[type="submit"] {
  width: auto;
  height: auto;
  margin: 0;
}
.wx-section {
  padding: 1rem 0;
  border-top: 1px solid #dce5ef;
}
.wx-section summary {
  min-height: 44px;
  line-height: 44px;
  font-weight: 650;
  cursor: pointer;
}
.wx-dialog .wx-check {
  display: flex;
  gap: .55rem;
  align-items: center;
  min-height: 44px;
  margin: 0;
  font-size: .875rem;
}
.wx-check input {
  width: 1rem;
  height: 1rem;
  margin: .1rem;
  accent-color: #1767ce;
}
.wx-preview {
  margin-top: .75rem;
  padding: .75rem;
  border: 1px solid #dce5ef;
  border-radius: 10px;
  background: #f3f7fb;
}
.wx-preview dl {
  margin: 0 0 .75rem;
}
.wx-preview dt {
  color: #405671;
  font-size: .8125rem;
}
.wx-preview dd {
  margin: 0 0 .65rem;
}
.wx-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.wx-notice-settings {
  margin-top: .9rem;
  padding-top: .9rem;
  border-top: 1px solid #dce5ef;
}
.wx-notice-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) min(46%, 10rem);
  align-items: center;
  gap: .8rem;
  padding: .35rem 0;
}
.wx-notice-row + .wx-notice-row { border-top: 1px solid #edf2f7; }
.wx-notice-row .wx-check { min-height: 44px; align-items: center; }

.wx-notice-master {
  margin: .65rem 0 .75rem;
  padding: .35rem .75rem .65rem;
  border: 1px solid #cfdeee;
  border-radius: 10px;
  background: #f3f7fb;
}
.wx-notice-master .wx-check { font-weight: 700; }
.wx-notice-master p {
  margin: 0;
  color: #405671;
  font-size: .8125rem;
}
.wx-notice-row .wx-check > input { flex: none; }
.wx-notice-row-state {
  display: block;
  margin-top: .12rem;
  color: #405671;
  font-size: .75rem;
}
.wx-notice-row-state[hidden] { display: none; }
