/* auth.css */
.auth-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000000;
  display: grid;
  place-items: center;
  padding: 16px;
  overflow-y: auto;
  background: rgba(7, 10, 14, 0.76);
  backdrop-filter: blur(7px);
  animation: auth-backdrop-in 160ms ease-out both;
}

.auth-backdrop[hidden],
.auth-form[hidden],
.auth-account-panel[hidden] {
  display: none !important;
}

.auth-dialog {
  position: relative;
  width: min(100%, 360px);
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  padding: 20px 20px 15px;
  border: 1px solid #3d4859;
  border-radius: 8px;
  background: #161c25;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.58), 0 0 0 1px rgba(134, 239, 172, 0.04);
  color: #f8fafc;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  transform-origin: top right;
  animation: auth-dialog-in 220ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.auth-dialog::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 2px;
  background: #22c55e;
}

.auth-heading {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding-right: 34px;
}

.auth-dialog h1 {
  margin: 0;
  color: #f8fafc;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0;
  text-align: left;
}

.auth-subtitle {
  margin: 2px 0 0;
  color: #8f9bab;
  font-size: 11.5px;
  line-height: 1.35;
}

.auth-icon-button {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  width: 30px;
  height: 30px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  font-size: 23px;
  line-height: 1;
}

.auth-icon-button:hover,
.auth-icon-button:focus-visible {
  background: #232c39;
  color: #ffffff;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 36px;
  margin: 14px 0 12px;
  padding: 3px;
  border: 1px solid #374151;
  border-radius: 7px;
  background: #10151d;
}

.auth-tab {
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  font-size: 13px;
  font-weight: 650;
  transition: background 130ms ease, color 130ms ease, transform 130ms ease;
}

.auth-tab.is-active {
  background: #2b3543;
  color: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.24);
}

.auth-tab:active {
  transform: scale(0.97);
}

.auth-tab:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.auth-form {
  display: flex;
  flex-direction: column;
}

.auth-form:not([hidden]) {
  animation: auth-panel-in 160ms ease-out both;
}

.auth-form > label {
  margin: 0 0 4px;
  color: #d1d5db;
  font-size: 12px;
  font-weight: 600;
}

.auth-form > input,
.auth-password-field > input {
  width: 100%;
  height: 39px;
  margin: 0 0 10px;
  padding: 0 11px;
  border: 1px solid #4b5563;
  border-radius: 6px;
  outline: none;
  background: #0e131a;
  color: #ffffff;
  font-family: inherit;
  font-size: 13px;
  line-height: 1.2;
  transition: border-color 130ms ease, box-shadow 130ms ease, background 130ms ease;
}

.auth-form > input:hover,
.auth-password-field > input:hover {
  border-color: #6b7280;
}

.auth-form > input:focus,
.auth-password-field > input:focus {
  border-color: #4ade80;
  box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.16);
}

.auth-password-field {
  position: relative;
  width: 100%;
  margin-bottom: 10px;
}

.auth-password-field > input {
  margin: 0;
  padding-right: 43px;
}

.auth-password-field > input[type="password"] {
  letter-spacing: normal;
}

.auth-inline-status {
  min-height: 0;
  margin: -5px 0 8px;
  color: #9ca3af;
  font-size: 11px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.auth-inline-status[hidden] {
  display: none;
}

.auth-inline-status.is-checking {
  color: #fbbf24;
}

.auth-inline-status.is-available {
  color: #4ade80;
}

.auth-inline-status.is-taken,
.auth-inline-status.is-reserved,
.auth-inline-status.is-invalid,
.auth-inline-status.is-offline {
  color: #ff5a5f;
}

.auth-password-toggle {
  position: absolute;
  top: 50%;
  right: 5px;
  display: grid;
  width: 32px;
  height: 31px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  transform: translateY(-50%);
}

.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  background: #232c39;
  color: #ffffff;
}

.auth-password-toggle svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.auth-password-toggle .auth-eye-hide,
.auth-password-toggle[aria-pressed="true"] .auth-eye-show {
  display: none;
}

.auth-password-toggle[aria-pressed="true"] .auth-eye-hide {
  display: block;
}

.auth-social-divider {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 13px 0 10px;
  color: #7f8b9b;
  font-size: 10px;
  text-transform: uppercase;
}

.auth-social-divider::before,
.auth-social-divider::after {
  height: 1px;
  background: #303947;
  content: "";
  flex: 1;
}

.auth-social-logins {
  display: grid;
  gap: 7px;
}

.auth-social-login {
  display: flex;
  min-width: 0;
  height: 40px;
  gap: 6px;
  align-items: center;
  justify-content: center;
  border: 1px solid #4b5563;
  border-radius: 6px;
  background: #10151d;
  color: #e5e7eb !important;
  font-size: 12px;
  font-weight: 650;
  text-decoration: none !important;
  transition: border-color 130ms ease, background 130ms ease, transform 110ms ease;
}

.auth-social-login:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.auth-social-login:hover,
.auth-social-login:focus-visible {
  border-color: #6b7280;
  background: #232c39;
}

.auth-social-login:active {
  transform: scale(0.97);
}

.auth-social-login svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
}

.auth-provider-discord {
  fill: #5865f2;
}

.auth-provider-github {
  fill: #ffffff;
}

.auth-social-note {
  margin: 8px 2px 0;
  color: #7f8b9b;
  font-size: 10px;
  line-height: 1.4;
  text-align: center;
}

.auth-agreement {
  margin: 9px 4px 0;
  color: #7f8b9b;
  font-size: 11px;
  line-height: 1.45;
  text-align: center;
}

.auth-dialog a {
  color: #86efac;
  text-decoration: none;
}

.auth-dialog a:hover,
.auth-dialog a:focus-visible {
  text-decoration: underline;
}

.auth-primary-button,
.auth-secondary-button {
  width: 100%;
  min-height: 40px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  transition: transform 110ms ease, background 130ms ease, border-color 130ms ease, box-shadow 130ms ease;
}

.auth-primary-button {
  margin-top: 4px;
  border: 1px solid #22c55e;
  background: #22c55e;
  color: #07140b;
  box-shadow: 0 5px 16px rgba(34, 197, 94, 0.17);
}

.auth-primary-button:hover,
.auth-primary-button:focus-visible {
  border-color: #4ade80;
  background: #4ade80;
  box-shadow: 0 7px 22px rgba(34, 197, 94, 0.25);
}

.auth-primary-button:active,
.auth-secondary-button:active {
  transform: translateY(1px) scale(0.985);
}

.auth-secondary-button {
  margin-top: 16px;
  border: 1px solid #4b5563;
  background: transparent;
  color: #f8fafc;
}

.auth-secondary-button:hover,
.auth-secondary-button:focus-visible {
  background: #2b3543;
}

.auth-primary-button:disabled,
.auth-secondary-button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.auth-primary-button.is-busy {
  position: relative;
  padding-right: 38px;
}

.auth-primary-button.is-busy::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 14px;
  width: 13px;
  height: 13px;
  margin-top: -7px;
  border: 2px solid rgba(7, 20, 11, 0.28);
  border-top-color: #07140b;
  border-radius: 50%;
  animation: auth-spin 600ms linear infinite;
}

.auth-status {
  display: none;
  margin: 0 0 10px;
  padding: 8px 10px;
  border: 1px solid #7f1d1d;
  border-radius: 6px;
  background: rgba(127, 29, 29, 0.22);
  color: #fecaca;
  font-size: 12px;
  line-height: 1.4;
}

.auth-status.is-visible {
  display: block;
}

.auth-account-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 14px 0 2px;
}

.auth-avatar {
  width: 52px;
  height: 52px;
  margin-bottom: 10px;
  border: 2px solid #4ade80;
  border-radius: 50%;
  background: #232c39;
}

.auth-account-panel strong {
  color: #ffffff;
  font-size: 16px;
}

.auth-account-panel span {
  margin-top: 4px;
  color: #9ca3af;
  font-size: 13px;
  overflow-wrap: anywhere;
}

.auth-legal {
  display: flex;
  justify-content: center;
  gap: 9px;
  margin-top: 12px;
  padding-top: 11px;
  border-top: 1px solid #303947;
  color: #6b7280;
  font-size: 11px;
}

#auth-menu-trigger {
  width: 100%;
  padding: 10px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #ffffff;
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  text-align: left;
}

#auth-menu-trigger:hover,
#auth-menu-trigger:focus-visible {
  background: rgba(255, 255, 255, 0.08);
  outline: none;
}

.auth-backdrop.is-closing {
  animation: auth-backdrop-out 130ms ease-in both;
}

.auth-backdrop.is-closing .auth-dialog {
  animation: auth-dialog-out 130ms ease-in both;
}

.auth-dialog.is-success {
  animation: auth-success 460ms ease-out both;
  border-color: #22c55e;
}

body.auth-dialog-open {
  overflow: hidden !important;
}

@media (max-width: 480px) {
  .auth-backdrop {
    align-items: end;
    padding: 0;
  }

  .auth-dialog {
    width: 100%;
    max-height: 94vh;
    padding: 20px 18px 14px;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 8px 8px 0 0;
  }
}

/* Final 2023 Modd.io auth shell. */
.auth-backdrop {
  place-items: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: none;
}

.auth-dialog {
  width: min(100%, 384px);
  max-height: calc(100vh - 32px);
  padding: 16px;
  border: 1px solid #4b5563;
  border-radius: 16px;
  background: #f3f4f6;
  box-shadow: 0 20px 25px rgba(0, 0, 0, 0.24);
  color: #111827;
  font-family: var(--font-rubik, 'Cabin', Arial, sans-serif);
}

.auth-heading {
  min-height: 42px;
  padding: 0 34px 0 8px;
}

.auth-dialog h1 {
  color: #111827;
  font-size: 20px;
  font-weight: 600;
  line-height: 24px;
}

.auth-subtitle {
  margin-top: 5px;
  color: #4b5563;
  font-size: 13px;
  line-height: 18px;
}

.auth-icon-button {
  top: 8px;
  right: 8px;
  color: #4b5563;
}

.auth-icon-button:hover,
.auth-icon-button:focus-visible {
  background: #e5e7eb;
  color: #1f2937;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 40px;
  margin: 16px 0;
  padding: 4px;
  border: 0;
  border-radius: 8px;
  background: #e5e7eb;
}

.auth-tab {
  min-width: 0;
  margin: 0;
  padding: 8px 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #4b5563;
  font-size: 14px;
  font-weight: 600;
}

.auth-tab:hover,
.auth-tab:focus-visible {
  background: rgba(255, 255, 255, 0.55);
  color: #111827;
}

.auth-tab.is-active {
  background: #1a56db;
  color: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
}

.auth-form > label {
  color: #374151;
  font-size: 13px;
  font-weight: 600;
}

.auth-form > input,
.auth-password-field > input {
  height: 40px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: #e5e7eb;
  color: #111827;
  font-size: 14px;
}

.auth-form > input:focus,
.auth-password-field > input:focus {
  border-color: #1a56db;
  box-shadow: 0 0 0 3px rgba(26, 86, 219, 0.18);
}

.auth-password-toggle {
  color: #4b5563;
}

.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  background: #d1d5db;
  color: #111827;
}

.auth-social-divider {
  color: #6b7280;
}

.auth-social-divider::before,
.auth-social-divider::after {
  background: #d1d5db;
}

.auth-social-login {
  height: 40px;
  border: 1px solid #9ca3af;
  border-radius: 6px;
  background: #f9fafb;
  color: #1f2937 !important;
}

.auth-social-login:hover,
.auth-social-login:focus-visible {
  border-color: #1a56db;
  background: #ffffff;
}

.auth-primary-button {
  border-color: #1a56db;
  border-radius: 6px;
  background: #1a56db;
  color: #ffffff;
}

.auth-primary-button:hover,
.auth-primary-button:focus-visible {
  border-color: #1e429f;
  background: #1e429f;
  box-shadow: 0 0 0 3px rgba(26, 86, 219, 0.18);
}

.auth-status {
  border-radius: 6px;
}

@media (max-width: 480px) {
  .auth-dialog {
    width: calc(100% - 16px);
    max-height: calc(100vh - 16px);
    padding: 16px;
    border: 1px solid #4b5563;
    border-radius: 16px;
  }
}

/* Modd.io play-page shell captured 2023-12-07. */
.auth-backdrop {
  padding: 16px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: none;
}

.auth-dialog {
  width: min(100%, 384px);
  max-height: calc(100vh - 32px);
  padding: 16px;
  overflow-y: auto;
  border: 1px solid #4b5563;
  border-radius: 16px;
  background: #f3f4f6;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.28), 0 8px 10px -6px rgba(0, 0, 0, 0.28);
  color: #111827;
  font-family: var(--font-rubik), Arial, sans-serif;
}

.auth-heading {
  min-height: 40px;
  padding-right: 32px;
}

.auth-dialog h1 {
  color: #111827;
  font-size: 20px;
  font-weight: 600;
  line-height: 24px;
}

.auth-subtitle {
  margin-top: 8px;
  color: #4b5563;
  font-size: 14px;
  line-height: 20px;
}

.auth-icon-button {
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  color: #4b5563;
}

.auth-icon-button:hover,
.auth-icon-button:focus-visible {
  background: #e5e7eb;
  color: #374151;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 40px;
  margin: 16px 0;
  padding: 4px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #e5e7eb;
}

.auth-tab {
  min-width: 0;
  margin: 0;
  padding: 8px 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #4b5563;
  font-size: 14px;
  font-weight: 500;
}

.auth-tab:hover,
.auth-tab:focus-visible {
  color: #111827;
}

.auth-tab.is-active {
  border: 0;
  background: #ffffff;
  color: #111827;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

.auth-form > label {
  margin-bottom: 4px;
  color: #374151;
  font-size: 14px;
  font-weight: 500;
}

.auth-form > input,
.auth-password-field > input {
  height: 40px;
  margin-bottom: 12px;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: #e5e7eb;
  color: #111827;
  font-size: 14px;
}

.auth-form > input:hover,
.auth-password-field > input:hover {
  border-color: #9ca3af;
}

.auth-form > input:focus,
.auth-password-field > input:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.24);
}

.auth-password-field {
  margin-bottom: 12px;
}

.auth-password-field > input {
  margin-bottom: 0;
}

.auth-password-toggle {
  color: #4b5563;
}

.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  background: #d1d5db;
  color: #111827;
}

.auth-social-divider {
  margin: 16px 0 12px;
  color: #6b7280;
}

.auth-social-divider::before,
.auth-social-divider::after {
  background: #d1d5db;
}

.auth-social-login {
  height: 40px;
  border: 1px solid #9ca3af;
  border-radius: 6px;
  background: transparent;
  color: #111827 !important;
  font-size: 14px;
  font-weight: 500;
}

.auth-social-login:hover,
.auth-social-login:focus-visible {
  border-color: #2563eb;
  background: #e5e7eb;
}

.auth-provider-github {
  fill: #111827;
}

.auth-social-note,
.auth-agreement,
.auth-account-panel span,
.auth-legal {
  color: #6b7280;
}

.auth-dialog a {
  color: #2563eb;
}

.auth-primary-button,
.auth-secondary-button {
  min-height: 40px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
}

.auth-primary-button {
  border-color: #2563eb;
  background: #2563eb;
  color: #ffffff;
  box-shadow: none;
}

.auth-primary-button:hover,
.auth-primary-button:focus-visible {
  border-color: #1d4ed8;
  background: #1d4ed8;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.24);
}

.auth-secondary-button {
  border-color: #9ca3af;
  background: transparent;
  color: #111827;
}

.auth-secondary-button:hover,
.auth-secondary-button:focus-visible {
  background: #e5e7eb;
}

.auth-status {
  border-color: #fca5a5;
  border-radius: 6px;
  background: #fee2e2;
  color: #991b1b;
}

.auth-account-panel strong {
  color: #111827;
}

.auth-avatar {
  border-color: #9ca3af;
  background: #e5e7eb;
}

.auth-legal {
  border-top-color: #d1d5db;
}

@media (max-width: 480px) {
  .auth-dialog {
    width: 100%;
    max-height: calc(100vh - 16px);
    padding: 16px;
    border: 1px solid #4b5563;
    border-radius: 16px;
  }
}

@keyframes auth-backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes auth-backdrop-out {
  from { opacity: 1; }
  to { opacity: 0; }
}

@keyframes auth-dialog-in {
  from { opacity: 0; transform: translateY(-8px) scale(0.94); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes auth-dialog-out {
  from { opacity: 1; transform: translateY(0) scale(1); }
  to { opacity: 0; transform: translateY(-5px) scale(0.97); }
}

@keyframes auth-panel-in {
  from { opacity: 0; transform: translateX(7px); }
  to { opacity: 1; transform: translateX(0); }
}

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

@keyframes auth-success {
  0% { transform: scale(1); }
  45% { transform: scale(1.018); box-shadow: 0 24px 74px rgba(0, 0, 0, 0.58), 0 0 24px rgba(34, 197, 94, 0.2); }
  100% { transform: scale(1); }
}

@media (prefers-reduced-motion: reduce) {
  .auth-backdrop,
  .auth-dialog,
  .auth-form:not([hidden]),
  .auth-primary-button.is-busy::after {
    animation-duration: 1ms !important;
  }
}

/* Modd.io 2023 player-shell treatment: compact Bootstrap-era account tabs. */
.auth-backdrop {
  padding: 20px;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: none;
}

.auth-dialog {
  width: min(100%, 420px);
  max-height: calc(100vh - 40px);
  padding: 22px 24px 16px;
  border: 1px solid #c8cdd3;
  border-radius: 5px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.42);
  color: #212529;
  font-family: 'Cabin', Arial, sans-serif;
  transform-origin: center;
}

.auth-dialog::before {
  display: none;
}

.auth-heading {
  min-height: 48px;
  padding: 0 36px 0 0;
}

.auth-dialog h1 {
  color: #212529;
  font-size: 24px;
  font-weight: 700;
}

.auth-subtitle {
  margin-top: 4px;
  color: #6c757d;
  font-size: 13px;
}

.auth-icon-button {
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border-radius: 4px;
  color: #6c757d;
}

.auth-icon-button:hover,
.auth-icon-button:focus-visible {
  background: #f1f3f5;
  color: #212529;
}

.auth-tabs {
  display: flex;
  min-height: 39px;
  margin: 18px 0 16px;
  padding: 0;
  border: 0;
  border-bottom: 1px solid #dee2e6;
  border-radius: 0;
  background: transparent;
}

.auth-tab {
  min-width: 92px;
  margin: 0 3px -1px 0;
  padding: 9px 16px;
  border: 1px solid transparent;
  border-radius: 5px 5px 0 0;
  background: transparent;
  color: #6c757d;
  font-size: 14px;
  font-weight: 700;
}

.auth-tab:hover,
.auth-tab:focus-visible {
  border-color: #e9ecef #e9ecef #dee2e6;
  color: #212529;
}

.auth-tab.is-active {
  border-color: #dee2e6 #dee2e6 #ffffff;
  background: #ffffff;
  color: #212529;
  box-shadow: none;
}

.auth-form > label {
  margin-bottom: 5px;
  color: #343a40;
  font-size: 13px;
  font-weight: 700;
}

.auth-form > input,
.auth-password-field > input {
  height: 40px;
  margin-bottom: 13px;
  padding: 8px 11px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  background: #ffffff;
  color: #212529;
  font-size: 14px;
}

.auth-form > input:hover,
.auth-password-field > input:hover {
  border-color: #adb5bd;
}

.auth-form > input:focus,
.auth-password-field > input:focus {
  border-color: #80bdff;
  box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.18);
}

.auth-password-field {
  margin-bottom: 13px;
}

.auth-password-field > input {
  margin-bottom: 0;
}

.auth-password-toggle {
  right: 4px;
  color: #6c757d;
}

.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  background: #f1f3f5;
  color: #212529;
}

.auth-social-divider {
  margin: 16px 0 12px;
  color: #6c757d;
}

.auth-social-divider::before,
.auth-social-divider::after {
  background: #dee2e6;
}

.auth-social-login {
  height: 40px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  background: #ffffff;
  color: #343a40 !important;
  font-size: 13px;
}

.auth-social-login:hover,
.auth-social-login:focus-visible {
  border-color: #adb5bd;
  background: #f8f9fa;
}

.auth-provider-github {
  fill: #212529;
}

.auth-social-note,
.auth-agreement {
  color: #6c757d;
}

.auth-dialog a {
  color: #1565c0;
}

.auth-primary-button,
.auth-secondary-button {
  min-height: 40px;
  border-radius: 4px;
  font-size: 14px;
}

.auth-primary-button {
  border-color: #218838;
  background: #28a745;
  color: #ffffff;
  box-shadow: none;
}

.auth-primary-button:hover,
.auth-primary-button:focus-visible {
  border-color: #1e7e34;
  background: #218838;
  box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.2);
}

.auth-secondary-button {
  border-color: #6c757d;
  background: #6c757d;
  color: #ffffff;
}

.auth-secondary-button:hover,
.auth-secondary-button:focus-visible {
  background: #5a6268;
}

.auth-status {
  border-color: #f1b0b7;
  border-radius: 4px;
  background: #f8d7da;
  color: #721c24;
}

.auth-account-panel strong {
  color: #212529;
}

.auth-account-panel span {
  color: #6c757d;
}

.auth-avatar {
  border-color: #adb5bd;
  background: #e9ecef;
}

.auth-legal {
  border-top-color: #dee2e6;
  color: #6c757d;
}

.auth-dialog.is-success {
  border-color: #28a745;
}

@media (max-width: 480px) {
  .auth-backdrop {
    padding: 8px;
  }

  .auth-dialog {
    width: 100%;
    max-height: calc(100vh - 16px);
    padding: 20px 18px 14px;
    border: 1px solid #c8cdd3;
    border-radius: 5px;
  }

  .auth-tab {
    flex: 1;
  }
}

#top-right-auth-region {
  position: fixed;
  top: 10px;
  right: 12px;
  z-index: 120002;
  display: flex;
  gap: 10px;
  align-items: center;
}

#selected-region-indicator {
  color: #ffffff;
  font: 700 13px/1 'Cabin', Arial, sans-serif;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
  white-space: nowrap;
}

#auth-menu-trigger {
  position: static;
  display: flex;
  width: auto;
  max-width: 220px;
  height: 36px;
  gap: 7px;
  align-items: center;
  padding: 0 14px 0 11px;
  border: 1px solid #374151;
  border-radius: 20px;
  background: #1f2937;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  color: #d1d5db;
  cursor: pointer;
  font: 500 13px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-align: left;
}

#auth-menu-trigger:hover,
#auth-menu-trigger:focus-visible {
  background: #273449;
  color: #ffffff;
  outline: none;
}

#auth-menu-trigger > i {
  color: #9ca3af;
  font-size: 15px;
}

#auth-menu-trigger.is-authenticated > i {
  color: #22c55e;
}

#auth-menu-trigger-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 575px) {
  #top-right-auth-region {
    top: 6px;
    right: 6px;
    gap: 7px;
  }

  #auth-menu-trigger {
    max-width: 150px;
    height: 34px;
    padding: 0 11px;
    font-size: 12px;
  }

  #selected-region-indicator {
    font-size: 12px;
  }
}

/* Professional account shell and compact game status controls. */
.auth-backdrop {
  background: rgba(8, 10, 14, 0.62);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.auth-dialog {
  width: min(100%, 400px);
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  background: rgba(48, 52, 60, 0.96);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.48);
  color: #f9fafb;
}

.auth-dialog::before {
  display: none;
}

.auth-heading {
  min-height: 46px;
  padding-right: 34px;
}

.auth-dialog h1,
.auth-form > label,
.auth-account-panel strong {
  color: #ffffff;
}

.auth-dialog h1 {
  font-size: 22px;
  line-height: 1.2;
}

.auth-subtitle,
.auth-social-note,
.auth-agreement,
.auth-account-panel span,
.auth-legal {
  color: #b8bec8;
}

.auth-status {
  margin-top: 14px;
}

.auth-form {
  margin-top: 18px;
}

.auth-form > input,
.auth-password-field > input {
  height: 42px;
  border: 1px solid #5a606b;
  border-radius: 6px;
  background: #252930;
  color: #ffffff !important;
}

.auth-form > input:hover,
.auth-password-field > input:hover {
  border-color: #737b88;
  background: #292e36;
}

.auth-form > input:focus,
.auth-password-field > input:focus {
  border-color: #3b82f6;
  background: #252930;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.auth-icon-button,
.auth-password-toggle {
  color: #c4c9d1;
}

.auth-icon-button:hover,
.auth-icon-button:focus-visible,
.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.auth-primary-button {
  min-height: 42px;
  border-color: #2563eb;
  border-radius: 6px;
  background: #2563eb;
  color: #ffffff;
  box-shadow: none;
}

.auth-primary-button:hover,
.auth-primary-button:focus-visible {
  border-color: #1d4ed8;
  background: #1d4ed8;
  color: #ffffff;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.22);
}

.auth-social-divider {
  color: #9ca3af;
}

.auth-social-divider::before,
.auth-social-divider::after {
  background: rgba(255, 255, 255, 0.12);
}

.auth-social-login {
  border-color: #5a606b;
  background: #292d34;
  color: #f3f4f6 !important;
}

.auth-social-login:hover,
.auth-social-login:focus-visible {
  border-color: #737b88;
  background: #333841;
}

.auth-provider-github {
  fill: #ffffff;
}

.auth-dialog a,
.auth-mode-switch button {
  color: #60a5fa;
}

.auth-mode-switch {
  margin: 16px 0 0;
  color: #b8bec8;
  font-size: 13px;
  text-align: center;
}

.auth-mode-switch button {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
}

.auth-mode-switch button:hover,
.auth-mode-switch button:focus-visible {
  color: #93c5fd;
  outline: none;
  text-decoration: underline;
}

.auth-legal {
  border-top-color: rgba(255, 255, 255, 0.12);
}

#stats {
  position: relative;
  top: 4px;
  height: auto;
  gap: 9px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  box-shadow: none;
  color: #ffffff;
  font-size: 10px;
  font-weight: 400;
}

#stats .hud-stat > span,
#stats .hud-stat:first-child > span,
#stats .hud-stat:last-child > span {
  color: #ffffff;
  font-weight: 400;
}

#stats .hud-engine-version {
  color: #ffffff;
}

#auth-menu-trigger {
  min-width: 92px;
  justify-content: center;
  border-color: #2563eb;
  border-radius: 7px;
  background: #2563eb;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.28);
}

#auth-menu-trigger:hover,
#auth-menu-trigger:focus-visible {
  border-color: #1d4ed8;
  background: #1d4ed8;
  color: #ffffff;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.22);
}

#auth-menu-trigger > i {
  color: #ffffff;
}

@media (max-width: 575px) {
  #stats {
    top: 3px;
    padding: 0;
    font-size: 9px;
  }

  #auth-menu-trigger {
    flex: 0 0 auto;
    width: auto;
    min-width: 78px;
    padding: 0 10px;
  }

  #auth-menu-trigger-label {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
  }

  .auth-dialog {
    padding: 20px;
    border-color: rgba(255, 255, 255, 0.12);
    border-radius: 10px;
  }
}

/* Final Modd.io-style gray auth shell. */
.auth-dialog {
  width: min(100%, 410px);
  padding: 20px;
  border: 1px solid #6b7280;
  border-radius: 16px;
  background: #d1d5db;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.58);
  color: #111827;
}

.auth-heading,
.auth-dialog h1,
.auth-form > label,
.auth-account-panel strong {
  color: #111827;
}

.auth-subtitle,
.auth-social-note,
.auth-agreement,
.auth-account-panel span,
.auth-legal {
  color: #4b5563;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin: 16px 0;
  padding: 4px;
  border: 1px solid #9ca3af;
  border-radius: 10px;
  background: #9ca3af;
}

.auth-tab {
  min-height: 38px;
  margin: 0;
  padding: 0 14px;
  border: 0;
  border-radius: 7px;
  color: #374151;
  background: transparent;
}

.auth-tab.is-active {
  color: #ffffff;
  background: #1a56db;
  box-shadow: 0 2px 6px rgba(26, 86, 219, 0.28);
}

.auth-form > input,
.auth-password-field > input,
.auth-social-login {
  border-color: #9ca3af;
  background: #f3f4f6;
  color: #111827 !important;
}

.auth-social-login:hover,
.auth-social-login:focus-visible {
  border-color: #6b7280;
  background: #e5e7eb;
}

.auth-icon-button,
.auth-password-toggle {
  color: #4b5563;
}

.auth-icon-button:hover,
.auth-icon-button:focus-visible,
.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  color: #111827;
  background: #e5e7eb;
}

.auth-legal {
  border-top-color: #9ca3af;
}

/* Frosted account surface and compact top-right connection controls. */
.auth-backdrop {
  background: rgba(10, 13, 18, 0.56);
  -webkit-backdrop-filter: blur(10px) saturate(120%);
  backdrop-filter: blur(10px) saturate(120%);
}

.auth-dialog {
  width: min(100%, 410px);
  padding: 20px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 12px;
  background: rgba(52, 57, 66, 0.72);
  -webkit-backdrop-filter: blur(24px) saturate(145%);
  backdrop-filter: blur(24px) saturate(145%);
  box-shadow:
    0 28px 70px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  color: #f8fafc;
}

.auth-dialog::before {
  display: block;
  height: 3px;
  border-radius: 12px 12px 0 0;
  background: linear-gradient(90deg, #40e0d0, #7ee787 34%, #ffd166 66%, #ff6b9d);
}

.auth-heading,
.auth-dialog h1,
.auth-form > label,
.auth-account-panel strong {
  color: #f8fafc;
}

.auth-subtitle,
.auth-social-note,
.auth-agreement,
.auth-account-panel span,
.auth-legal {
  color: #cbd5e1;
}

.auth-tabs {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(12, 16, 23, 0.34);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.auth-tab {
  color: #cbd5e1;
}

.auth-tab:hover,
.auth-tab:focus-visible {
  border-color: transparent;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.auth-tab.is-active {
  color: #0f172a;
  background: #7ee787;
  box-shadow: 0 4px 14px rgba(126, 231, 135, 0.28);
}

.auth-form > input,
.auth-password-field > input,
.auth-social-login {
  border-color: rgba(255, 255, 255, 0.17);
  background: rgba(15, 19, 27, 0.46);
  color: #ffffff !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.auth-form > input:hover,
.auth-password-field > input:hover,
.auth-social-login:hover,
.auth-social-login:focus-visible {
  border-color: rgba(64, 224, 208, 0.7);
  background: rgba(15, 19, 27, 0.6);
}

.auth-form > input:focus,
.auth-password-field > input:focus {
  border-color: #40e0d0;
  box-shadow: 0 0 0 3px rgba(64, 224, 208, 0.18);
}

.auth-icon-button,
.auth-password-toggle {
  color: #cbd5e1;
}

.auth-icon-button:hover,
.auth-icon-button:focus-visible,
.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

.auth-social-divider {
  color: #aeb8c7;
}

.auth-social-divider::before,
.auth-social-divider::after {
  background: rgba(255, 255, 255, 0.15);
}

.auth-provider-github {
  fill: #ffffff;
}

.auth-dialog a {
  color: #67e8f9;
}

.auth-primary-button {
  border-color: #35c978;
  background: #35c978;
  color: #07140d;
  box-shadow: 0 6px 18px rgba(53, 201, 120, 0.24);
}

.auth-primary-button:hover,
.auth-primary-button:focus-visible {
  border-color: #40e0d0;
  background: #40e0d0;
  color: #071316;
  box-shadow: 0 0 0 3px rgba(64, 224, 208, 0.2);
}

.auth-secondary-button {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.auth-secondary-button:hover,
.auth-secondary-button:focus-visible {
  background: rgba(255, 255, 255, 0.14);
}

.auth-legal {
  border-top-color: rgba(255, 255, 255, 0.14);
}

#stats {
  display: flex;
  height: 34px;
  gap: 8px;
  align-items: center;
  padding: 0 11px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 17px;
  background: rgba(31, 41, 55, 0.62);
  -webkit-backdrop-filter: blur(12px) saturate(135%);
  backdrop-filter: blur(12px) saturate(135%);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.32);
  color: #cbd5e1;
  font: 500 11px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  pointer-events: none;
  white-space: nowrap;
}

#stats .hud-stat > span {
  color: #ffffff;
  font-weight: 700;
}

#stats .hud-stat:first-child > span {
  color: #40e0d0;
}

#stats .hud-stat:last-child > span {
  color: #7ee787;
}

.hud-stat-divider {
  width: 1px;
  height: 14px;
  background: rgba(255, 255, 255, 0.18);
}

#auth-menu-trigger {
  border-color: rgba(255, 255, 255, 0.17);
  background: rgba(31, 41, 55, 0.7);
  -webkit-backdrop-filter: blur(12px) saturate(135%);
  backdrop-filter: blur(12px) saturate(135%);
}

#auth-menu-trigger:hover,
#auth-menu-trigger:focus-visible {
  border-color: rgba(126, 231, 135, 0.55);
  background: rgba(42, 54, 70, 0.82);
  box-shadow: 0 0 0 3px rgba(126, 231, 135, 0.12);
}

#auth-menu-trigger > i {
  color: #ffce63;
}

@media (max-width: 575px) {
  #top-right-auth-region {
    gap: 6px;
  }

  #selected-region-indicator {
    display: none;
  }

  #stats {
    height: 32px;
    gap: 6px;
    padding: 0 9px;
    font-size: 10px;
  }

  #auth-menu-trigger {
    flex: 0 0 34px;
    width: 34px;
    padding: 0;
    justify-content: center;
  }

  #auth-menu-trigger-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }

  .auth-dialog {
    border-color: rgba(255, 255, 255, 0.22);
    border-radius: 12px;
  }
}

/* Authoritative minimal account theme. */
.auth-backdrop {
  background: rgba(8, 10, 14, 0.62);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.auth-dialog {
  width: min(100%, 400px);
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  background: rgba(48, 52, 60, 0.96);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.48);
  color: #f9fafb;
}

.auth-dialog::before {
  display: none;
}

.auth-heading {
  min-height: 46px;
  padding-right: 34px;
}

.auth-dialog h1,
.auth-form > label,
.auth-account-panel strong {
  color: #ffffff;
}

.auth-dialog h1 {
  font-size: 22px;
  line-height: 1.2;
}

.auth-subtitle,
.auth-social-note,
.auth-agreement,
.auth-account-panel span,
.auth-legal {
  color: #b8bec8;
}

.auth-status {
  margin-top: 14px;
}

.auth-form {
  margin-top: 18px;
}

.auth-form > input,
.auth-password-field > input {
  height: 42px;
  border: 1px solid #5a606b;
  border-radius: 6px;
  background: #252930;
  color: #ffffff !important;
}

.auth-form > input:hover,
.auth-password-field > input:hover {
  border-color: #737b88;
  background: #292e36;
}

.auth-form > input:focus,
.auth-password-field > input:focus {
  border-color: #3b82f6;
  background: #252930;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.auth-icon-button,
.auth-password-toggle {
  color: #c4c9d1;
}

.auth-icon-button:hover,
.auth-icon-button:focus-visible,
.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.auth-primary-button {
  min-height: 42px;
  border-color: #2563eb;
  border-radius: 6px;
  background: #2563eb;
  color: #ffffff;
  box-shadow: none;
}

.auth-primary-button:hover,
.auth-primary-button:focus-visible {
  border-color: #1d4ed8;
  background: #1d4ed8;
  color: #ffffff;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.22);
}

.auth-social-divider {
  color: #9ca3af;
}

.auth-social-divider::before,
.auth-social-divider::after {
  background: rgba(255, 255, 255, 0.12);
}

.auth-social-login {
  border-color: #5a606b;
  background: #292d34;
  color: #f3f4f6 !important;
}

.auth-social-login:hover,
.auth-social-login:focus-visible {
  border-color: #737b88;
  background: #333841;
}

.auth-provider-github {
  fill: #ffffff;
}

.auth-dialog a,
.auth-mode-switch button {
  color: #60a5fa;
}

.auth-mode-switch {
  margin: 16px 0 0;
  color: #b8bec8;
  font-size: 13px;
  text-align: center;
}

.auth-mode-switch button {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
}

.auth-mode-switch button:hover,
.auth-mode-switch button:focus-visible {
  color: #93c5fd;
  outline: none;
  text-decoration: underline;
}

.auth-legal {
  border-top-color: rgba(255, 255, 255, 0.12);
}

#stats {
  border-color: rgba(255, 255, 255, 0.13);
  background: rgba(39, 43, 51, 0.92);
  color: #c5cad3;
}

#stats .hud-stat > span,
#stats .hud-stat:first-child > span,
#stats .hud-stat:last-child > span {
  color: #ffffff;
}

#stats .hud-engine-version {
  color: #aeb5c0;
}

#auth-menu-trigger {
  min-width: 92px;
  justify-content: center;
  border-color: #2563eb;
  border-radius: 7px;
  background: #2563eb;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.28);
}

#auth-menu-trigger:hover,
#auth-menu-trigger:focus-visible {
  border-color: #1d4ed8;
  background: #1d4ed8;
  color: #ffffff;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.22);
}

#auth-menu-trigger > i {
  color: #ffffff;
}

@media (max-width: 575px) {
  #stats {
    padding: 0 8px;
    font-size: 9px;
  }

  #auth-menu-trigger {
    flex: 0 0 auto;
    width: auto;
    min-width: 78px;
    padding: 0 10px;
  }

  #auth-menu-trigger-label {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
  }

  .auth-dialog {
    padding: 20px;
    border-color: rgba(255, 255, 255, 0.12);
    border-radius: 10px;
  }
}

/* Plain status text beside Sign In. */
#stats {
  position: relative;
  top: 3px;
  display: flex;
  width: auto;
  height: auto;
  gap: 7px;
  align-items: center;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  box-shadow: none;
  color: #ffffff;
  font: 400 10px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  white-space: nowrap;
}

#stats .hud-stat,
#stats .hud-stat > span,
#stats .hud-version {
  color: #ffffff;
  font-weight: 400;
}

@media (max-width: 575px) {
  #stats {
    top: 2px;
    gap: 5px;
    padding: 0;
    font-size: 9px;
  }
}

/* Keep the connection readout as unframed text only. */
#top-right-auth-region #stats {
  min-width: 0 !important;
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  outline: 0 !important;
  background: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  box-shadow: none !important;
}

#top-right-auth-region #stats::before,
#top-right-auth-region #stats::after,
#top-right-auth-region #stats .hud-stat {
  border: 0 !important;
  border-radius: 0 !important;
  background: none !important;
  box-shadow: none !important;
}

#auth-menu-trigger {
  gap: 0;
  height: 38px;
  padding-right: 15px;
  padding-left: 15px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
}

#auth-menu-trigger-label {
  height: auto;
  padding: 1px 0 2px;
  overflow: visible;
  line-height: 1.35;
  text-overflow: clip;
}

/* Final top-right account and connection layout. */
#top-right-auth-region {
  top: 8px;
  align-items: flex-start;
}

#connection-status {
  display: flex;
  flex-direction: column;
  gap: 3px;
  align-items: flex-end;
  padding-top: 0;
}

#guest-connection-label {
  color: #ffffff;
  font: 400 10px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  white-space: nowrap;
}

#top-right-auth-region #stats {
  top: 0;
}

#auth-menu-trigger {
  min-width: 0;
  max-width: 150px;
  height: 30px;
  padding: 0 9px;
  font-size: 15px;
  line-height: 1.3;
}

#auth-menu-trigger-label {
  padding: 1px 0 2px;
  line-height: 1.3;
}

#braains-coin-balance {
  display: flex;
  min-width: 48px;
  height: 30px;
  margin-right: -6px;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 2px 7px;
  border-radius: 4px;
  border: 1px solid #252a2f;
  background: #353a40 !important;
  color: #ffffff;
  font: 700 14px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07), 0 1px 3px rgba(0, 0, 0, 0.42);
  cursor: pointer;
  user-select: none;
}

#braains-coin-balance:hover,
#braains-coin-balance:focus-visible {
  border-color: #5b6570;
  background: #414850 !important;
  outline: 2px solid #86b7fe;
  outline-offset: 1px;
}

#braains-coin-balance[hidden] {
  display: none !important;
}

#braains-coin-balance img {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
}

@media (max-width: 575px) {
  #connection-status {
    gap: 3px;
  }

  #guest-connection-label {
    font-size: 9px;
  }

  #auth-menu-trigger {
    min-width: 0;
    max-width: 130px;
    height: 29px;
    padding: 0 8px;
    font-size: 14px;
  }

  #braains-coin-balance {
    min-width: 44px;
    height: 29px;
    margin-right: -3px;
    padding: 2px 6px;
    font-size: 13px;
  }
}

#auth-menu-trigger {
  width: max-content;
  min-width: 68px;
  max-width: min(240px, calc(100vw - 12px));
  flex: 0 1 auto;
  justify-content: space-between;
}

#auth-menu-trigger.is-authenticated {
  width: max-content;
  min-width: 86px;
  max-width: min(240px, calc(100vw - 12px));
}

#auth-menu-trigger-label {
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#auth-menu-chevron {
  position: relative;
  display: none;
  width: 10px;
  height: 10px;
  flex: 0 0 auto;
  margin-left: 4px;
  color: currentColor;
  font-size: 0;
  line-height: 0;
}

#auth-menu-trigger.is-authenticated #auth-menu-chevron {
  display: inline-block;
}

#auth-menu-chevron::before {
  position: absolute;
  top: calc(50% - 2px);
  left: 50%;
  width: 6px;
  height: 6px;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  content: "";
  transform: translate(-50%, -50%) rotate(45deg);
  transform-origin: center;
}

#auth-menu-trigger[aria-expanded="true"] #auth-menu-chevron::before {
  transform: translate(-50%, -50%) rotate(225deg);
}

@media (max-width: 575px) {
  #auth-menu-trigger {
    width: max-content;
    max-width: min(180px, calc(100vw - 112px));
  }

  #auth-menu-trigger.is-authenticated {
    width: max-content;
    min-width: 86px;
  }

  #auth-menu-trigger-label {
    position: static;
    width: auto;
    height: auto;
    overflow: hidden;
    clip: auto;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

/* Modd.io November 2024 / May 2025 account picker and profile settings. */
.auth-account-menu[hidden],
.braains-coin-picker[hidden],
.auth-settings-backdrop[hidden],
.auth-profile-picture-backdrop[hidden],
.auth-delete-backdrop[hidden],
#auth-profile-view[hidden],
#auth-settings-view[hidden],
#auth-security-view[hidden],
#auth-coins-transactions-view[hidden] {
  display: none !important;
}

#auth-purchase-pin-form[hidden] {
  display: none !important;
}

.auth-account-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 120004;
  width: 192px;
  overflow: hidden;
  border: 1px solid #30363d;
  border-radius: 6px;
  background: #171b20;
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.48);
  color: #cdd4dc;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  transform-origin: top right;
  animation: shared-picker-in 180ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
  backface-visibility: hidden;
}

.auth-account-menu button {
  display: flex;
  width: 100%;
  min-height: 38px;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  border: 0;
  border-bottom: 1px solid #2b3138;
  background: #171b20;
  color: #cdd4dc;
  cursor: pointer;
  font: 500 14px/1.25 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-align: left;
  transition: background-color 140ms ease, color 140ms ease, transform 140ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.auth-account-menu button:last-child {
  border-bottom: 0;
}

.auth-account-menu button:hover,
.auth-account-menu button:focus-visible {
  background: #242a31;
  color: #e1e6eb;
  outline: none;
  transform: translateX(2px);
}

.auth-account-menu button:active {
  transform: translateX(1px) scale(0.99);
}

@keyframes shared-picker-in {
  from {
    opacity: 0;
    transform: translate3d(0, -6px, 0) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

.auth-account-menu button span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-account-menu button i {
  flex: 0 0 auto;
  margin-left: 12px;
  color: #7f8a96;
  font-size: 14px;
}

.braains-wallet-trigger {
  position: relative;
  flex: 0 0 auto;
}

.auth-settings-backdrop,
.auth-profile-picture-backdrop,
.auth-delete-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000001;
  display: grid;
  place-items: center;
  padding: 18px;
  overflow-y: auto;
  background: rgba(0, 0, 0, 0.68);
}

.auth-settings-dialog {
  width: min(100%, 1040px);
  max-height: calc(100vh - 36px);
  overflow: hidden;
  border: 1px solid #3a3d44;
  border-radius: 8px;
  background: #16181a;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
  color: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-settings-header {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid #3a3d44;
}

.auth-settings-header h1 {
  margin: 0;
  color: #ffffff;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0;
}

.auth-settings-header button,
.auth-delete-dialog header button {
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  font-size: 25px;
  line-height: 1;
}

.auth-settings-header button:hover,
.auth-settings-header button:focus-visible,
.auth-delete-dialog header button:hover,
.auth-delete-dialog header button:focus-visible {
  background: #2b2f35;
  color: #ffffff;
  outline: none;
}

.auth-settings-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  min-height: min(620px, calc(100vh - 96px));
}

.auth-settings-tabs {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px 12px;
  border-right: 1px solid #3a3d44;
  background: #131313;
}

.auth-settings-tabs button {
  display: flex;
  width: 100%;
  min-height: 38px;
  gap: 10px;
  align-items: center;
  padding: 9px 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  font: 600 14px/1.25 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-settings-tabs button:hover,
.auth-settings-tabs button:focus-visible {
  background: #202328;
  color: #ffffff;
  outline: none;
}

.auth-settings-tabs button.is-active {
  background: #282e37;
  color: #ffffff;
}

.auth-settings-tabs button i {
  width: 16px;
  color: #77808e;
  text-align: center;
}

.auth-settings-tabs button.is-active i {
  color: #ffffff;
}

.auth-settings-content {
  min-width: 0;
  max-height: calc(100vh - 96px);
  overflow-y: auto;
  background: #16181a;
}

.auth-settings-status {
  display: none;
  margin: 14px 18px 0;
  padding: 10px 12px;
  border: 1px solid #86efac;
  border-radius: 5px;
  background: #dcfce7;
  color: #166534;
  font-size: 13px;
}

.auth-settings-status.is-visible {
  display: block;
}

.auth-settings-status.is-error {
  border-color: #fca5a5;
  background: #fee2e2;
  color: #991b1b;
}

.auth-profile-view {
  display: grid;
  grid-template-columns: 144px minmax(0, 1fr);
  gap: 30px;
  align-items: start;
  padding: 32px;
}

.auth-profile-picture-button {
  position: relative;
  width: 144px;
  height: 144px;
  overflow: hidden;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: #2f3339;
  cursor: pointer;
}

.auth-profile-picture-button > img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.auth-profile-picture-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.3);
  color: #111827;
  font-size: 34px;
  opacity: 0;
  transition: opacity 150ms ease;
}

.auth-profile-picture-button:hover .auth-profile-picture-overlay,
.auth-profile-picture-button:focus-visible .auth-profile-picture-overlay {
  opacity: 1;
}

.auth-profile-picture-button:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 3px;
}

.auth-profile-copy {
  min-width: 0;
  padding-top: 4px;
}

.auth-profile-view h2 {
  margin: 0;
  color: #ffffff;
  font-size: 28px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.auth-profile-view p {
  margin: 8px 0 0;
  color: #c7cbd1;
  font-size: 14px;
  line-height: 1.45;
  white-space: pre-wrap;
}

.auth-profile-social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.auth-profile-social-links a {
  display: inline-flex;
  max-width: 180px;
  overflow: hidden;
  padding: 5px 8px;
  border: 1px solid #4b5563;
  border-radius: 4px;
  color: #d1d5db;
  font-size: 12px;
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-profile-social-links a:hover,
.auth-profile-social-links a:focus-visible {
  border-color: #60a5fa;
  color: #ffffff;
  outline: none;
}

.auth-profile-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 150px));
  gap: 10px;
  margin: 18px 0 0;
}

.auth-profile-stats div {
  padding: 12px 14px;
  border: 1px solid #3a3d44;
  border-radius: 5px;
  background: #202328;
}

.auth-profile-stats dt {
  color: #9ca3af;
  font-size: 11px;
  text-transform: uppercase;
}

.auth-profile-stats dd {
  margin: 4px 0 0;
  color: #ffffff;
  font-size: 18px;
  font-weight: 600;
}

.auth-profile-form {
  padding: 24px;
}

.auth-settings-panel {
  border: 2px solid #3a3d44;
  border-radius: 8px;
}

.auth-settings-panel h2 {
  margin: 0;
  padding: 18px 20px 4px;
  color: #ffffff;
  font-size: 24px;
  font-weight: 600;
}

.auth-profile-field,
.auth-profile-checkbox {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(0, 2fr);
  gap: 12px;
  align-items: center;
  margin: 14px 20px;
}

.auth-profile-field label,
.auth-profile-checkbox span {
  color: #e5e7eb;
  font-size: 13px;
  font-weight: 500;
}

.auth-profile-field input,
.auth-profile-field textarea {
  width: 100%;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid #4c5158;
  border-radius: 5px;
  background: #2b2f31;
  color: #eceeef;
  font: 400 14px/1.35 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-profile-field input:hover,
.auth-profile-field textarea:hover {
  border-color: #697177;
}

.auth-profile-field input:focus,
.auth-profile-field textarea:focus {
  border-color: #3b82f6;
  outline: 2px solid rgba(59, 130, 246, 0.25);
  outline-offset: 1px;
}

.auth-profile-field input:disabled {
  color: #8e949c;
  cursor: not-allowed;
}

.auth-profile-field textarea {
  resize: vertical;
}

.auth-profile-field small {
  grid-column: 2;
  margin-top: -7px;
  color: #9ca3af;
  font-size: 11px;
  text-align: right;
}

.auth-profile-checkbox {
  grid-template-columns: minmax(120px, 1fr) minmax(0, 2fr);
}

.auth-profile-checkbox input {
  grid-column: 2;
  grid-row: 1;
  width: 18px;
  height: 18px;
}

.auth-profile-checkbox span {
  grid-column: 1;
  grid-row: 1;
}

.auth-settings-panel footer {
  display: flex;
  justify-content: flex-end;
  padding: 12px 20px;
  border-top: 1px solid #3a3d44;
  background: #202328;
}

.auth-settings-save,
.auth-session-panel button,
.auth-delete-dialog footer button {
  min-height: 34px;
  padding: 7px 13px;
  border: 1px solid #2563eb;
  border-radius: 5px;
  background: #2563eb;
  color: #ffffff;
  cursor: pointer;
  font: 600 13px/1.2 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-settings-save:hover,
.auth-settings-save:focus-visible {
  background: #1d4ed8;
  outline: none;
}

.auth-session-panel {
  margin: 0 24px 24px;
  padding: 8px 16px;
  border: 1px solid #3a3d44;
  border-radius: 8px;
  background: #202328;
  color: #e5e7eb;
}

.auth-session-panel > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #3a3d44;
}

.auth-session-panel > div:last-child {
  border-bottom: 0;
}

.auth-session-panel span {
  font-size: 13px;
  font-weight: 500;
}

.auth-session-panel button {
  border-color: #5a6069;
  background: #30343a;
  color: #ffffff;
}

.auth-session-panel button:hover,
.auth-session-panel button:focus-visible {
  background: #424850;
  outline: none;
}

.auth-profile-picture-backdrop {
  z-index: 1000002;
}

.auth-profile-picture-dialog {
  width: min(100%, 760px);
  overflow: hidden;
  border: 1px solid #3a3d44;
  border-radius: 16px;
  background: #16181a;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.58);
  color: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-profile-picture-dialog > header {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #3a3d44;
}

.auth-profile-picture-dialog h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
}

.auth-profile-picture-dialog > header button {
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  font-size: 25px;
}

.auth-profile-picture-dialog > header button:hover,
.auth-profile-picture-dialog > header button:focus-visible {
  background: #2b2f35;
  color: #ffffff;
  outline: none;
}

.auth-profile-picture-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 24px;
  align-items: center;
  padding: 24px;
}

.auth-profile-picture-preview {
  display: grid;
  min-height: 320px;
  place-items: center;
  border: 1px solid #3a3d44;
  border-radius: 8px;
  background: #202328;
}

.auth-profile-picture-preview img {
  width: min(280px, 100%);
  aspect-ratio: 1;
  border-radius: 8px;
  object-fit: cover;
}

.auth-profile-picture-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-profile-picture-upload,
.auth-profile-picture-apply {
  display: inline-flex;
  width: 100%;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 9px 14px;
  border: 1px solid #4c5158;
  border-radius: 6px;
  background: #30343a;
  color: #ffffff;
  cursor: pointer;
  font: 600 14px/1.2 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-profile-picture-upload:hover,
.auth-profile-picture-upload:focus-visible {
  border-color: #3b82f6;
  background: #3b4149;
  outline: none;
}

.auth-profile-picture-apply {
  border-color: #2563eb;
  background: #2563eb;
}

.auth-profile-picture-apply:not(:disabled):hover,
.auth-profile-picture-apply:not(:disabled):focus-visible {
  background: #1d4ed8;
  outline: none;
}

.auth-profile-picture-apply:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.auth-session-panel button.is-danger,
.auth-delete-dialog footer button.is-danger {
  border-color: #dc2626;
  background: #dc2626;
  color: #ffffff;
}

.auth-session-panel button.is-danger:hover,
.auth-session-panel button.is-danger:focus-visible,
.auth-delete-dialog footer button.is-danger:hover,
.auth-delete-dialog footer button.is-danger:focus-visible {
  background: #b91c1c;
}

.auth-delete-backdrop {
  z-index: 1000002;
}

.auth-delete-dialog {
  width: min(100%, 560px);
  overflow: hidden;
  border-radius: 14px;
  background: #f9fafb;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
  color: #111827;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-delete-dialog header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
}

.auth-delete-dialog h2 {
  margin: 0;
  font-size: 25px;
  font-weight: 500;
}

.auth-delete-dialog header button {
  color: #6b7280;
}

#auth-delete-description {
  padding: 0 20px 18px;
  font-size: 14px;
  line-height: 1.5;
}

.auth-delete-warning {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #d1d5db;
  border-radius: 5px;
  color: #a16207;
}

.auth-delete-warning p {
  margin: 8px 0 0;
}

.auth-delete-dialog footer {
  display: flex;
  justify-content: space-between;
  padding: 0 20px 20px;
}

.auth-delete-dialog footer button:not(.is-danger) {
  border-color: #6b7280;
  background: #ffffff;
  color: #111827;
}

@media (max-width: 640px) {
  .auth-settings-backdrop,
  .auth-profile-picture-backdrop,
  .auth-delete-backdrop {
    padding: 8px;
  }

  .auth-settings-dialog {
    max-height: calc(100vh - 16px);
  }

  .auth-settings-shell {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .auth-settings-tabs {
    flex-direction: row;
    padding: 8px;
    border-right: 0;
    border-bottom: 1px solid #3a3d44;
  }

  .auth-settings-tabs button {
    justify-content: center;
  }

  .auth-settings-content {
    max-height: calc(100vh - 132px);
  }

  .auth-profile-view {
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 16px;
    padding: 20px 16px;
  }

  .auth-profile-picture-button {
    width: 88px;
    height: 88px;
  }

  .auth-profile-view h2 {
    font-size: 21px;
  }

  .auth-profile-stats {
    grid-template-columns: 1fr 1fr;
  }

  .auth-profile-form {
    padding: 12px;
  }

  .auth-profile-field,
  .auth-profile-checkbox {
    grid-template-columns: 1fr;
    gap: 6px;
    margin: 12px;
  }

  .auth-profile-field small,
  .auth-profile-checkbox input,
  .auth-profile-checkbox span {
    grid-column: 1;
  }

  .auth-profile-checkbox input {
    grid-row: 2;
  }

  .auth-profile-checkbox span {
    grid-row: 1;
  }

  .auth-session-panel {
    margin: 0 12px 12px;
  }

  .auth-session-panel > div {
    grid-template-columns: 1fr;
  }

  .auth-session-panel button {
    width: 100%;
  }

  .auth-profile-picture-dialog {
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 10px 10px 0 0;
  }

  .auth-profile-picture-body {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 16px;
  }

  .auth-profile-picture-preview {
    min-height: 240px;
  }

  .auth-profile-picture-preview img {
    width: min(220px, 100%);
  }
}

.auth-form > .auth-policy-consent {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 9px;
  align-items: start;
  margin: 2px 2px 10px;
  color: #b8bec8;
  font-size: 11px;
  font-weight: 400;
  line-height: 1.45;
  text-align: left;
}

.auth-policy-consent input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin: 1px 0 0;
  accent-color: #60b98a;
  cursor: pointer;
}

.auth-policy-consent span {
  min-width: 0;
}

/* Braains Io original notification UI, extracted from the 2025-11-14 source build. */
.braains-notification-trigger {
  position: relative;
  flex: 0 0 auto;
}

#braains-notification-button {
  position: relative;
  display: inline-flex;
  width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  padding: 3px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #ffffff;
  cursor: pointer;
}

#braains-notification-button:hover,
#braains-notification-button:focus-visible,
#braains-notification-button[aria-expanded="true"] {
  background: rgba(249, 250, 251, 0.16);
  color: #ffffff;
  outline: 2px solid #86b7fe;
  outline-offset: 1px;
}

#braains-notification-button[hidden],
#braains-notification-badge[hidden],
#braains-notification-panel[hidden],
.braains-notification-footer[hidden] {
  display: none !important;
}

#braains-notification-button > i {
  width: 24px;
  height: 24px;
  color: #ffffff;
  font-size: 22px;
  line-height: 24px;
  text-align: center;
}

#braains-notification-badge,
.braains-notification-tab-badge {
  display: inline-flex;
  min-width: 18px;
  height: 18px;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}

#braains-notification-badge {
  position: absolute;
  top: -5px;
  right: -6px;
  background: #ef4444;
  color: #ffffff;
}

#braains-notification-panel {
  position: fixed;
  top: 44px;
  right: 12px;
  z-index: 120005;
  display: flex;
  width: min(760px, calc(100vw - 24px));
  max-height: min(360px, calc(100vh - 56px));
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #353b43;
  border-radius: 6px;
  background: #161618;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.58);
  color: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  transform-origin: top right;
}

#braains-notification-panel.is-opening {
  animation: braains-notification-open var(--braains-notification-enter-duration) var(--braains-notification-enter-timing) both;
}

#braains-notification-panel.is-closing {
  animation: braains-notification-close var(--braains-notification-leave-duration) var(--braains-notification-leave-timing) both;
  pointer-events: none;
}

@keyframes braains-notification-open {
  from {
    opacity: 0;
    transform: scale(var(--braains-notification-from-scale));
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes braains-notification-close {
  from {
    opacity: 1;
    transform: scale(1);
  }

  to {
    opacity: 0;
    transform: scale(var(--braains-notification-from-scale));
  }
}

.braains-notification-header {
  display: flex;
  min-height: 34px;
  align-items: center;
  justify-content: space-between;
  padding: 4px 6px 4px 10px;
  background: #161618;
}

.braains-notification-header h2 {
  margin: 0;
  color: #ffffff;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.25;
}

#braains-notification-close {
  display: inline-flex;
  width: 28px;
  height: 28px;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: #d2d5da;
  cursor: pointer;
}

#braains-notification-close:hover,
#braains-notification-close:focus-visible {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  outline: 2px solid #86b7fe;
  outline-offset: 1px;
}

.braains-notification-filter {
  display: flex;
  width: 100%;
  height: auto;
  min-height: 28px;
  align-items: center;
  justify-content: space-between;
  padding: 0 4px;
  border-radius: 0 0 6px 6px;
  background: #282e36;
}

.braains-notification-filter > strong {
  flex: 0 0 auto;
  margin: 0 6px;
  font-size: 12px;
  white-space: nowrap;
}

#braains-notification-tabs {
  display: flex;
  min-width: 0;
  flex: 1 1 auto;
  align-items: stretch;
  overflow-x: auto;
  scrollbar-width: thin;
}

.braains-notification-tab {
  display: inline-flex;
  height: 26px;
  min-width: max-content;
  flex: 1 0 auto;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin: 0 3px;
  padding: 0 6px;
  border: 0;
  border-bottom: 1px solid white;
  background: #282e36;
  color: #ffffff;
  cursor: pointer;
  font: 600 12px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  white-space: nowrap;
}

.braains-notification-tab:hover,
.braains-notification-tab:focus-visible {
  background: #20252c;
  outline: 2px solid #86b7fe;
  outline-offset: -2px;
}

.braains-notification-tab.is-selected {
  border-bottom: 3px solid #e5e7eb;
  background: #1b1b1e;
}

.braains-notification-tab-badge {
  background: #d9e3fd;
  color: #274199;
}

.braains-notification-mobile-filter {
  display: none;
  min-width: 0;
  flex: 1 1 auto;
  padding: 3px 4px;
  border-bottom: 3px solid #e5e7eb;
  background: #1b1b1e;
}

#braains-notification-select {
  width: 100%;
  border: 0;
  background: #1b1b1e;
  color: #ffffff;
  font: 500 12px/1.3 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

#braains-notification-list {
  min-height: 72px;
  margin-top: 6px;
  overflow-y: auto;
  border-radius: 6px;
  background: #161618;
}

#braains-notification-list[aria-busy="true"] {
  display: grid;
  place-items: center;
}

.braains-notification-empty,
.braains-notification-loading,
.braains-notification-error {
  display: flex;
  min-height: 72px;
  align-items: center;
  justify-content: center;
  padding: 10px;
  color: #ffffff;
  font-size: 13px;
  text-align: center;
}

.braains-notification-error {
  color: #fca5a5;
}

.braains-notification-row {
  display: flex;
  min-height: 32px;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 2px 4px;
  padding: 4px 7px;
  border-bottom: 1px solid #6b7280;
  border-radius: 2px;
  color: #ffffff;
}

.braains-notification-row.is-unread {
  background: #394150;
}

.braains-notification-row:hover {
  border-bottom-color: #374151;
}

.braains-notification-row.is-follower {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
}

.braains-notification-avatar-button {
  display: grid;
  width: 32px;
  height: 32px;
  overflow: hidden;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: #282e36;
  cursor: pointer;
}

.braains-notification-avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.braains-notification-message {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #ffffff;
  font-size: 12px;
  line-height: 1.35;
}

.braains-notification-profile-link {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.braains-notification-profile-link strong {
  color: #60a5fa;
  font-weight: 700;
  text-decoration: underline;
}

.braains-notification-avatar-button:focus-visible,
.braains-notification-profile-link:focus-visible {
  outline: 2px solid #86b7fe;
  outline-offset: 2px;
}

a.braains-notification-message {
  color: #60a5fa;
  text-decoration: underline;
}

.braains-notification-time {
  flex: 0 0 auto;
  color: #d2d5da;
  font-size: 10px;
  white-space: nowrap;
}

.braains-notification-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 7px;
}

#braains-notification-load-more {
  min-height: 30px;
  padding: 4px 10px;
  border: 1px solid #4b525c;
  border-radius: 5px;
  background: #161618;
  color: #ffffff;
  cursor: pointer;
  font-weight: 600;
  font-size: 12px;
}

#braains-notification-load-more:hover,
#braains-notification-load-more:focus-visible {
  background: #282e36;
  outline: 2px solid #86b7fe;
  outline-offset: 1px;
}

@media (max-width: 767px) {
  #braains-notification-panel {
    top: 43px;
    right: 6px;
    width: calc(100vw - 12px);
    max-height: min(360px, calc(100vh - 49px));
  }

  #braains-notification-tabs {
    display: none;
  }

  .braains-notification-mobile-filter {
    display: block;
  }

  .braains-notification-time {
    max-width: 78px;
    text-align: right;
    white-space: normal;
  }
}

@media (min-width: 768px) and (max-width: 920px) {
  .braains-notification-tab {
    gap: 4px;
    margin: 0 2px;
    padding: 0 6px;
    font-size: 12px;
  }
}

@media (max-width: 575px) {
  #top-right-auth-region {
    top: 47px;
  }

  #braains-notification-panel {
    top: 83px;
    max-height: min(360px, calc(100vh - 89px));
  }

  #braains-notification-button {
    width: 29px;
    height: 29px;
  }

  #braains-notification-button > i {
    font-size: 20px;
  }

  .braains-notification-row {
    min-height: 32px;
    gap: 6px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .auth-account-menu {
    animation: none !important;
  }

  .auth-account-menu button {
    transition: none !important;
  }

  #braains-notification-panel.is-opening,
  #braains-notification-panel.is-closing {
    animation-duration: 1ms;
  }
}

/* May 28, 2025 Modd.io profile refinement. */
.auth-settings-backdrop {
  background: rgba(4, 7, 10, 0.78);
  backdrop-filter: blur(8px);
  z-index: 1000003;
}

.auth-settings-dialog {
  width: min(100%, 920px);
  max-height: calc(100vh - 48px);
  border-color: #30363d;
  border-radius: 7px;
  background: #15191d;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.62);
  color: #cdd4dc;
}

.auth-settings-header {
  min-height: 56px;
  padding: 12px 18px;
  border-color: #2b3138;
  background: #171b20;
}

.auth-settings-header h1 {
  color: #d7dde4;
  font-size: 18px;
}

.auth-settings-header button,
.auth-profile-picture-dialog > header button {
  color: #747f8b;
}

.auth-settings-shell {
  grid-template-columns: 228px minmax(0, 1fr);
  min-height: 430px;
}

.auth-settings-tabs {
  gap: 4px;
  padding: 16px 10px;
  border-color: #292f35;
  background: #111418;
}

.auth-settings-tabs button {
  min-height: 42px;
  padding: 10px 12px;
  border-left: 2px solid transparent;
  border-radius: 4px;
  color: #8e99a5;
  font-weight: 600;
}

.auth-settings-tabs button span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-settings-tabs button:hover,
.auth-settings-tabs button:focus-visible {
  background: #1b2026;
  color: #c8d0d8;
}

.auth-settings-tabs button.is-active {
  border-left-color: #60b98a;
  background: #20262c;
  color: #d7e4dc;
  box-shadow: inset 0 0 0 1px #2d343b;
}

.auth-settings-tabs button i,
.auth-settings-tabs button.is-active i {
  color: #718078;
}

.auth-settings-tabs button.is-active i {
  color: #70c899;
}

.auth-settings-content {
  max-height: calc(100vh - 104px);
  background: #15191d;
}

.auth-settings-status {
  margin: 16px 22px 0;
}

.auth-profile-view {
  grid-template-columns: 124px minmax(0, 1fr);
  gap: 26px;
  min-height: 330px;
  align-content: center;
  padding: 32px 36px;
}

.auth-profile-picture-button {
  width: 124px;
  height: 124px;
  border: 1px solid #353c44;
  border-radius: 6px;
  background: #20262c;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.24);
}

.auth-profile-picture-overlay {
  background: rgba(16, 22, 27, 0.7);
  color: #8fd8ae;
  font-size: 26px;
}

.auth-profile-picture-button:focus-visible {
  outline-color: #70c899;
}

.auth-profile-copy {
  min-width: 0;
  padding-top: 2px;
}

.auth-profile-view h2 {
  color: #dce2e8;
  font-size: 27px;
  line-height: 1.16;
}

.auth-profile-view p {
  max-width: 520px;
  color: #8d98a4;
  font-size: 13px;
}

.auth-profile-social-links a {
  border-color: #353d45;
  background: #1b2025;
  color: #9da8b3;
}

.auth-profile-stats {
  grid-template-columns: repeat(2, minmax(132px, 160px));
  gap: 12px;
  margin-top: 20px;
}

.auth-profile-stats div {
  padding: 12px 14px;
  border-color: #30373e;
  background: #1c2126;
}

.auth-profile-stats dt {
  color: #727e89;
}

.auth-profile-stats dd {
  color: #cbd5de;
  font-size: 17px;
}

.auth-profile-form {
  padding: 20px 22px;
}

.auth-settings-panel,
.auth-session-panel {
  border-width: 1px;
  border-color: #30373e;
  border-radius: 6px;
  background: #181d22;
}

.auth-settings-panel h2 {
  color: #ced5dc;
  font-size: 19px;
}

.auth-profile-field label,
.auth-profile-checkbox span,
.auth-session-panel {
  color: #aeb7c0;
}

.auth-profile-field input,
.auth-profile-field textarea {
  border-color: #384149;
  background: #11161a;
  color: #cbd3db;
}

.auth-settings-panel footer {
  border-color: #30373e;
  background: #151a1f;
}

.auth-settings-save,
.auth-profile-picture-apply {
  border-color: #408b65;
  background: #347456;
  color: #e1eee7;
}

.auth-settings-save:hover,
.auth-settings-save:focus-visible,
.auth-profile-picture-apply:not(:disabled):hover,
.auth-profile-picture-apply:not(:disabled):focus-visible {
  background: #3f8664;
}

.auth-session-panel {
  margin: 0 22px 22px;
}

/* Braains Io original security controls, using the July 22 PIN setup/reset flow. */
.auth-security-view {
  display: grid;
  gap: 14px;
  padding: 24px;
  background: #111418;
}

.auth-security-panel {
  position: relative;
  overflow: hidden;
  border: 1px solid #30373e;
  border-radius: 7px;
  background: #181d22;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.18), inset 0 0 0 1px rgba(255, 255, 255, 0.018);
}

.auth-security-panel::before {
  position: absolute;
  inset: 0 0 auto;
  height: 2px;
  background: #4f9b73;
  content: "";
}

.auth-security-panel-heading {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  justify-content: space-between;
  padding: 24px 22px 17px;
  border-bottom: 1px solid #30373e;
  background: #1a2025;
}

.auth-security-panel-heading h2,
.auth-security-form-heading h3 {
  margin: 0;
  color: #d7dde4;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0;
}

.auth-security-panel-heading p,
.auth-security-form-heading p {
  max-width: 640px;
  margin: 6px 0 0;
  color: #8e99a5;
  font-size: 13px;
  line-height: 1.6;
}

.auth-security-eyebrow {
  margin: 0 0 5px !important;
  color: #70c899 !important;
  font-size: 11px !important;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.auth-security-badge {
  flex: 0 0 auto;
  min-width: 82px;
  padding: 6px 9px;
  border: 1px solid #4b5560;
  border-radius: 4px;
  background: #20262c;
  color: #cdd4dc;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-align: center;
  white-space: nowrap;
}

.auth-security-badge.is-success {
  border-color: #408b65;
  background: #1f4a36;
  color: #a9e3bf;
}

.auth-security-badge.is-warning {
  border-color: #8a6b3f;
  background: #3a2f1d;
  color: #e7c58a;
}

.auth-security-badge.is-neutral {
  background: #20262c;
}

.auth-security-summary {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 17px 22px 16px;
  padding: 13px 14px;
  border-left: 3px solid #4f9b73;
  border: 1px solid #30373e;
  border-left-width: 3px;
  background: #151a1f;
  color: #aeb7c0;
  font-size: 13px;
  line-height: 1.45;
}

.auth-security-summary i,
.auth-security-panel-icon {
  color: #70c899;
}

.auth-security-actions {
  display: flex;
  justify-content: flex-end;
  padding: 15px 22px 20px;
  border-top: 1px solid #30373e;
  background: #151a1f;
}

.auth-security-actions .auth-settings-save,
.auth-security-form-actions .auth-settings-save {
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

.auth-purchase-pin-form {
  margin: 17px 22px 18px;
  padding: 18px;
  border: 1px solid #384149;
  border-radius: 5px;
  background: #11161a;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.015);
}

.auth-security-field {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) minmax(0, 1.4fr);
  gap: 12px;
  align-items: center;
  margin-top: 13px;
}

.auth-security-field label {
  color: #aeb7c0;
  font-size: 13px;
}

.auth-security-field input {
  width: 100%;
  min-width: 0;
  min-height: 38px;
  padding: 9px 11px;
  border: 1px solid #384149;
  border-radius: 4px;
  background: #0c1013;
  color: #d7dde4;
  font: 400 14px/1.35 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-security-field input:focus {
  border-color: #60b98a;
  outline: 2px solid rgba(96, 185, 138, 0.25);
  outline-offset: 1px;
}

.auth-security-form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 19px;
  padding-top: 15px;
  border-top: 1px solid #30373e;
}

.auth-security-secondary {
  min-height: 34px;
  padding: 7px 13px;
  border: 1px solid #4b5560;
  border-radius: 5px;
  background: #20262c;
  color: #cdd4dc;
  cursor: pointer;
  font: 600 13px/1.2 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-security-secondary:hover,
.auth-security-secondary:focus-visible {
  border-color: #70c899;
  color: #ffffff;
  outline: none;
}

.auth-security-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 17px 22px 22px;
}

.auth-security-facts div {
  padding: 13px 14px;
  border: 1px solid #30373e;
  border-radius: 4px;
  background: #151a1f;
}

.auth-security-facts dt {
  color: #727e89;
  font-size: 11px;
  text-transform: uppercase;
}

.auth-security-facts dd {
  margin: 5px 0 0;
  color: #cbd5de;
  font-size: 13px;
  line-height: 1.35;
}

@media (max-width: 680px) {
  .auth-security-view { padding: 16px; }
  .auth-security-panel-heading { padding: 20px 16px 14px; }
  .auth-security-summary,
  .auth-purchase-pin-form { margin-left: 16px; margin-right: 16px; }
  .auth-security-actions { padding-left: 16px; padding-right: 16px; }
  .auth-security-facts { grid-template-columns: 1fr; padding-left: 16px; padding-right: 16px; }
  .auth-security-field { grid-template-columns: 1fr; gap: 6px; }
}

.auth-profile-picture-backdrop {
  background: rgba(4, 7, 10, 0.82);
  backdrop-filter: blur(8px);
  z-index: 1000004;
}

.auth-profile-picture-dialog {
  width: min(100%, 640px);
  border-color: #30373e;
  border-radius: 8px;
  background: #15191d;
  color: #cdd4dc;
}

.auth-profile-picture-dialog > header {
  border-color: #2b3138;
}

.auth-profile-picture-dialog h2 {
  color: #d5dce3;
}

.auth-profile-picture-body {
  grid-template-columns: minmax(0, 1fr) 188px;
  gap: 20px;
  padding: 20px;
}

.auth-profile-picture-preview {
  min-height: 280px;
  border-color: #30373e;
  background: #11161a;
}

.auth-profile-picture-preview img {
  width: min(240px, 100%);
}

.auth-profile-picture-upload {
  border-color: #3a444d;
  background: #20262c;
  color: #b9c3cc;
}

.auth-profile-picture-upload:hover,
.auth-profile-picture-upload:focus-visible {
  border-color: #5e9f7d;
  background: #262e34;
  color: #d5e3dc;
}

@media (max-width: 640px) {
  .auth-settings-dialog {
    max-height: calc(100vh - 16px);
  }

  .auth-settings-shell {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .auth-settings-tabs button {
    width: auto;
    min-width: 0;
    flex: 1 1 0;
    flex-direction: column;
    justify-content: center;
    border-bottom: 2px solid transparent;
    border-left: 0;
    padding: 6px 4px;
    font-size: 12px;
    gap: 3px;
    line-height: 1.1;
  }

  .auth-settings-tabs button i {
    width: auto;
  }

  .auth-settings-tabs button span {
    overflow: visible;
    text-align: center;
    text-overflow: clip;
    white-space: normal;
  }

  .auth-settings-tabs button.is-active {
    border-bottom-color: #60b98a;
  }

  .auth-profile-view {
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 14px;
    min-height: 0;
    padding: 22px 16px;
  }

  .auth-profile-picture-button {
    width: 82px;
    height: 82px;
  }

  .auth-profile-view h2 {
    font-size: 21px;
  }

  .auth-profile-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .auth-profile-picture-body {
    grid-template-columns: 1fr;
  }
}

/* Account terminal: a compact metal frame held by the game's robot helper. */
.auth-backdrop {
  --auth-panel: #2b2e2b;
  --auth-field: #20231f;
  --auth-text: #f3f3eb;
  --auth-muted: #babeb4;
  --auth-metal: #d7dcd0;
  --auth-accent: #e6b85c;
  z-index: 1000010;
  padding: 14px 24px;
  background: rgba(15, 17, 15, 0.8);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.auth-stage { position: relative; width: min(100%, 416px); min-width: 0; padding-top: 76px; }
.auth-stage .auth-dialog {
  position: relative;
  z-index: 2;
  width: 100%;
  max-height: calc(100dvh - 104px);
  padding: 18px 22px 16px;
  border: 1px solid #73796b;
  border-top: 2px solid var(--auth-metal);
  border-radius: 12px;
  background: var(--auth-panel);
  color: var(--auth-text);
  font-family: Cabin, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.45), inset 0 1px rgba(255, 255, 255, 0.08);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  scrollbar-color: #777e6e var(--auth-panel);
  scrollbar-width: thin;
  overscroll-behavior: contain;
  transform-origin: center top;
}
.auth-stage .auth-dialog::before { display: block; content: ''; position: absolute; inset: 4px; height: auto; border: 1px solid rgba(215, 220, 208, 0.06); border-radius: 8px; background: none; pointer-events: none; }
.auth-stage .auth-heading { min-height: 0; padding-right: 30px; }
.auth-stage .auth-dialog h1 { color: var(--auth-text); font-size: 27px; font-weight: 700; line-height: 1.12; letter-spacing: -0.6px; }
.auth-stage .auth-subtitle { margin: 4px 0 0; color: var(--auth-muted); font-size: 12px; line-height: 1.35; }
.auth-stage .auth-form { display: flex; flex-direction: column; gap: 0; margin-top: 13px; }
.auth-fields { display: grid; gap: 8px; }
.auth-field { min-width: 0; }
.auth-field-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.auth-stage .auth-field > label { display: block; margin: 0 0 4px; color: #dde1d5; font-size: 12px; font-weight: 600; line-height: 1.25; }
.auth-input-shell { position: relative; width: 100%; min-width: 0; }
.auth-stage .auth-input-shell > input {
  display: block;
  width: 100%;
  min-width: 0;
  height: 40px;
  margin: 0;
  padding: 0 11px 0 36px;
  border: 1px solid #555e4e;
  border-radius: 6px;
  outline: none;
  background: var(--auth-field);
  color: var(--auth-text) !important;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.2;
  box-shadow: inset 0 2px 3px rgba(0, 0, 0, 0.18);
  transition: border-color 120ms ease, box-shadow 120ms ease;
}
.auth-stage .auth-input-shell > input::placeholder { color: #8c9483; opacity: 1; }
.auth-stage .auth-input-shell > input:hover { border-color: #87917a; background: var(--auth-field); }
.auth-stage .auth-input-shell > input:focus { border-color: var(--auth-accent); background: var(--auth-field); box-shadow: 0 0 0 2px rgba(230, 184, 92, 0.12); }
.auth-stage .auth-input-shell > input:-webkit-autofill { -webkit-text-fill-color: var(--auth-text); box-shadow: inset 0 0 0 1000px var(--auth-field); caret-color: var(--auth-text); }
.auth-input-icon { position: absolute; z-index: 1; top: 12px; left: 12px; width: 16px; height: 16px; fill: none; stroke: #929b87; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; transition: stroke 120ms ease; }
.auth-input-shell:focus-within .auth-input-icon { stroke: var(--auth-accent); }
.auth-stage .auth-password-field { margin: 0; }
.auth-stage .auth-password-field > input { padding-right: 38px; }
.auth-stage .auth-password-toggle { right: 1px; width: 36px; height: 38px; color: #a7b099; }
.auth-stage .auth-password-toggle svg { width: 17px; height: 17px; }
.auth-stage .auth-icon-button { top: 8px; right: 9px; width: 36px; height: 36px; color: #a7b099; }
.auth-stage .auth-icon-button:hover,
.auth-stage .auth-password-toggle:hover { color: var(--auth-text); background: rgba(215, 220, 208, 0.08); }
.auth-stage button:focus-visible,
.auth-stage a:focus-visible { outline: 2px solid var(--auth-accent); outline-offset: 3px; }
.auth-stage .auth-form > .auth-policy-consent { min-height: 20px; margin: 8px 0 0; gap: 6px; color: var(--auth-muted); font-size: 11px; line-height: 1.4; }
.auth-stage .auth-policy-consent + .auth-policy-consent { margin-top: 3px; }
.auth-stage .auth-policy-consent input[type='checkbox'] { accent-color: var(--auth-accent); }
.auth-stage .auth-inline-status { margin: 4px 0 0; }
.auth-stage .auth-status { margin: 10px 0 0; }
.auth-stage .auth-primary-button { min-height: 42px; margin-top: 9px; border: 1px solid #cfa052; border-radius: 6px; background: var(--auth-accent); color: #252a21; font-family: inherit; font-size: 14px; font-weight: 700; box-shadow: inset 0 1px rgba(255, 245, 205, 0.4), 0 2px 0 #927139; }
.auth-stage .auth-primary-button:hover,
.auth-stage .auth-primary-button:focus-visible { border-color: #f2cc7f; background: #f2cc7f; color: #252a21; box-shadow: inset 0 1px rgba(255, 245, 205, 0.5), 0 2px 0 #927139; }
.auth-stage .auth-primary-button:active { transform: translateY(1px); box-shadow: inset 0 1px rgba(255, 245, 205, 0.4), 0 1px 0 #927139; }
.auth-stage .auth-primary-button:disabled { cursor: not-allowed; opacity: 0.6; }
.auth-stage .auth-primary-button.is-busy { cursor: wait; }
.auth-stage .auth-social-divider { margin: 10px 0 8px; color: #a2ac97; font-size: 11px; }
.auth-stage .auth-social-divider::before,
.auth-stage .auth-social-divider::after { background: #505949; }
.auth-stage .auth-social-logins { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; }
.auth-stage .auth-social-login { display: flex; align-items: center; justify-content: center; gap: 6px; min-width: 0; min-height: 38px; padding: 0 6px; border: 1px solid #5b6553; border-radius: 6px; background: #343a2f; color: var(--auth-text) !important; box-shadow: inset 0 1px rgba(215, 220, 208, 0.06); font-family: inherit; font-size: 12px; }
.auth-stage .auth-social-login svg { width: 16px; height: 16px; flex-shrink: 0; }
.auth-stage .auth-social-divider span { text-transform: none; letter-spacing: 0; }
.auth-stage .auth-social-login:hover,
.auth-stage .auth-social-login:focus-visible { border-color: #97a08a; background: #3d4536; }
.auth-stage .auth-social-note { margin: 5px 0 0; color: var(--auth-muted); font-size: 11px; }
.auth-stage .auth-social-note:empty { display: none; }
.auth-stage .auth-agreement { margin: 8px 0 0; color: var(--auth-muted); font-size: 11px; line-height: 1.4; }
.auth-stage .auth-mode-switch { margin: 12px -22px -16px; padding: 9px 22px 11px; border-top: 1px solid #454e3c; background: #23291f; color: var(--auth-muted); font-size: 12px; line-height: 1.5; }
.auth-stage .auth-dialog a,
.auth-stage .auth-mode-switch button { color: #efd294; }
.auth-stage .auth-dialog a:hover,
.auth-stage .auth-mode-switch button:hover { color: #ffe4aa; }
.auth-stage .auth-mode-switch button { padding: 2px 0; }
.auth-stage .auth-legal { display: none; }
.is-account .auth-stage .auth-legal { display: flex; margin-top: 12px; padding-top: 10px; border-top-color: #4c5544; color: var(--auth-muted); font-size: 11px; }
/* Metal faceplate, small ears and fingers wrapping around the terminal edge. */
.auth-cloud-bot { display: block; position: absolute; inset: 0; color: var(--auth-accent); pointer-events: none; }
.auth-bot-body { position: absolute; z-index: 1; top: 59px; left: calc(50% - 37px); width: 74px; height: 28px; border: 3px solid #89957c; border-radius: 9px 9px 0 0; background: #a6b098; }
.auth-bot-antenna { position: absolute; z-index: 3; top: -3px; left: calc(50% - 2px); width: 4px; height: 16px; border-radius: 4px; background: #a9b49c; }
.auth-bot-antenna::before { content: ''; position: absolute; top: -4px; left: -3px; width: 10px; height: 10px; border: 2px solid #e6b85c; border-radius: 50%; background: #bd9449; }
.auth-bot-head { position: absolute; z-index: 3; top: 10px; left: calc(50% - 63px); width: 126px; height: 62px; border: 2px solid #b2bea2; border-radius: 18px; background: #d7dfcc; box-shadow: inset 0 2px #f0f3e8, inset 0 -5px #abb99a, 0 2px 0 #536046, 0 4px 0 #171d13; animation: auth-bot-arrive 420ms ease-out both; }
.auth-bot-head::before { content: ''; position: absolute; inset: 9px 10px 10px; border: 2px solid #6d7e5b; border-radius: 10px; background: #202b18; box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.45), 0 1px #e9efdf; }
.auth-bot-head::after { content: ''; position: absolute; top: 27px; left: 4px; width: 3px; height: 3px; border-radius: 50%; background: #889977; box-shadow: 110px 0 #889977; }
.auth-bot-puff { position: absolute; z-index: -1; top: 18px; width: 12px; height: 23px; border: 2px solid #8b9a7a; border-radius: 4px; background: #bdc8ae; box-shadow: inset 0 -3px #8c9b7b; }
.auth-bot-puff-left { left: -10px; }
.auth-bot-puff-right { right: -10px; }
.auth-bot-eyes { position: absolute; top: 22px; left: 31px; width: 8px; height: 10px; border-radius: 3px; background: currentColor; box-shadow: 48px 0 currentColor; transform-origin: center; animation: auth-bot-blink 6s infinite; transition: transform 180ms ease; }
.auth-bot-mouth { position: absolute; top: 32px; left: 55px; width: 12px; height: 7px; border-bottom: 2px solid currentColor; border-radius: 0 0 50% 50%; }
.auth-bot-arm { position: absolute; z-index: 3; top: 62px; width: calc(50% - 37px); height: 61px; border: 8px solid #b2bea2; border-bottom: 0; background: transparent; }
.auth-bot-arm-left { left: -13px; border-right: 0; border-radius: 29px 0 0 0; }
.auth-bot-arm-right { right: -13px; border-left: 0; border-radius: 0 29px 0 0; }
.auth-bot-hand { position: absolute; bottom: -9px; width: 25px; height: 32px; border: 2px solid #97a785; border-radius: 8px; background: #d7dfcc; box-shadow: inset 0 1px #f0f3e8, inset 0 -4px #abb99a, 0 2px 0 #536046; }
.auth-bot-hand::after { content: ''; position: absolute; top: 8px; left: 4px; width: 13px; height: 2px; background: #8c9d79; box-shadow: 0 6px #8c9d79; }
.auth-bot-arm-left .auth-bot-hand { left: -14px; }
.auth-bot-arm-right .auth-bot-hand { right: -14px; }
.is-password-focus .auth-bot-eyes { animation: none; transform: scaleY(0.18); }
.is-password-focus .auth-bot-head { animation: none; transform: rotate(-3deg); }
.is-account .auth-cloud-bot { display: none; }
.is-account .auth-stage { padding-top: 0; }
.is-account .auth-dialog { max-height: calc(100dvh - 28px); }
.auth-challenge { display: grid; justify-items: center; gap: 5px; min-width: 0; min-height: 65px; margin: 8px 0 0; }
.auth-challenge[hidden], .auth-challenge-status[hidden], .auth-challenge-retry[hidden] { display: none; }
.auth-challenge-widget { max-width: 100%; }
.auth-challenge-status { margin: 0; font: 12px/1.4 system-ui, sans-serif; color: #ffb7b7; text-align: center; }
.auth-challenge-retry { border: 0; background: none; padding: 4px 8px; color: #efd294; font-size: 13px; cursor: pointer; text-decoration: underline; }
@keyframes auth-bot-arrive { from { transform: translateY(7px) rotate(-5deg); } to { transform: translateY(0) rotate(0); } }
@keyframes auth-bot-blink { 0%, 42%, 46%, 100% { transform: scaleY(1); } 44% { transform: scaleY(0.12); } }
@media (max-width: 520px) {
  .auth-backdrop { padding: 12px 20px; }
  .auth-stage { padding-top: 72px; }
  .auth-stage .auth-dialog { max-height: calc(100dvh - 96px); padding: 17px 17px 15px; }
  .auth-stage .auth-dialog h1 { font-size: 26px; }
  .auth-stage .auth-input-shell > input { font-size: 16px; }
  .auth-stage .auth-mode-switch { margin-right: -17px; margin-left: -17px; margin-bottom: -15px; padding-right: 17px; padding-left: 17px; }
  .auth-bot-head { top: 7px; }
  .auth-bot-body { top: 56px; }
  .auth-bot-arm { top: 58px; }
}
@media (max-width: 360px) { .auth-field-pair { grid-template-columns: 1fr; gap: 8px; } }
@media (max-height: 540px) {
  .auth-stage { padding-top: 58px; }
  .auth-stage .auth-dialog { max-height: calc(100dvh - 82px); }
  .auth-bot-head { top: -7px; transform: scale(0.8); transform-origin: center bottom; animation: none; }
  .auth-bot-body { top: 44px; }
  .auth-bot-antenna { display: none; }
  .auth-bot-arm { top: 44px; height: 57px; }
  .is-password-focus .auth-bot-head { transform: scale(0.8) rotate(-3deg); }
}
@media (prefers-reduced-motion: reduce) {
  .auth-backdrop, .auth-backdrop.is-closing, .auth-stage .auth-dialog,
  .auth-backdrop.is-closing .auth-dialog, .auth-stage .auth-form:not([hidden]),
  .auth-bot-head, .auth-bot-eyes { animation: none; }
  .auth-stage input, .auth-stage button, .auth-bot-eyes, .auth-input-icon { transition: none; }
}

/* Verification follows the same compact account terminal. */
.auth-email-panel[hidden], .auth-email-panel [hidden] { display: none !important; }
.auth-email-art { display: block; width: 44px; height: 44px; margin: 0 auto 8px; fill: none; stroke: var(--auth-accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.auth-stage .auth-email-copy { margin: 0 0 12px; color: var(--auth-muted); font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.auth-stage .auth-email-copy:empty { display: none; }
.auth-stage #auth-email-resend-status { margin: 10px 0 0; }
.auth-stage #auth-email-resend { padding-left: 11px; }

/* Keep connection latency in the game HUD, outside the lobby presentation. */
body:not(.in-game) #stats > .hud-stat:first-child { display: none; }

.auth-referral-field > label span { color: #89939d; font-size: 11px; font-weight: 400; }
.auth-field-hint { display: block; margin: 4px 0 0 34px; color: #87939e; font-size: 11px; line-height: 1.35; }
.auth-stage #auth-referral-code-status.is-error { color: #efa18e; }
.auth-stage #auth-referral-code[aria-invalid="true"] { border-color: #d68a72; }
.auth-referral-view { padding: 24px; min-width: 0; }
.auth-referral-view[hidden], #auth-referral-generate[hidden] { display: none !important; }
.auth-referral-heading { display: flex; align-items: center; gap: 12px; padding-bottom: 20px; border-bottom: 1px solid #303a43; }
.auth-referral-heading > div { flex: 1; min-width: 0; }
.auth-referral-heading h2 { margin: 0; color: #e1e8e4; font-size: 21px; font-weight: 600; }
.auth-referral-heading p { margin: 6px 0 0; color: #9dabba; font-size: 13px; line-height: 1.5; }
.auth-referral-skin { width: 48px; height: 48px; flex: 0 0 48px; object-fit: contain; }
.auth-referral-icon { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; flex: 0 0 36px; padding: 0; border: 1px solid #39434c; border-radius: 4px; background: #20262c; color: #bec9d0; cursor: pointer; }
.auth-referral-icon:hover { background: #2b333b; color: #eef5f1; }
.auth-referral-icon.is-copied { border-color: #60b98a; color: #90d8af; background: #1e3025; }
.auth-referral-icon:focus-visible, .auth-referral-view input:focus-visible { outline: 2px solid #70c899; outline-offset: 2px; }
.auth-referral-icon:disabled, .auth-referral-view button:disabled { opacity: .45; cursor: default; }
.auth-referral-body { display: grid; gap: 20px; padding-top: 20px; }
.auth-referral-link-field { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; color: #aeb8c1; font-size: 12px; }
.auth-referral-link-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.auth-referral-link-row input { width: 100%; min-width: 0; height: 38px; box-sizing: border-box; border: 1px solid #39434c; border-radius: 4px; padding: 0 11px; color: #dce5eb; background: #11161a; font: 12px/1.2 ui-monospace, SFMono-Regular, Consolas, monospace; }
.auth-referral-link-field > button { justify-self: start; }
.auth-referral-view .auth-settings-save { display: inline-flex; justify-content: center; align-items: center; gap: 7px; min-height: 38px; border-radius: 4px; }
.auth-referral-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 0; padding: 16px 0; border-top: 1px solid #303a43; border-bottom: 1px solid #303a43; }
.auth-referral-facts div + div { border-left: 1px solid #303a43; padding-left: 12px; }
.auth-referral-facts dt { color: #929fa9; font-size: 12px; }
.auth-referral-facts dd { margin: 5px 0 0; color: #e2ebe5; font-size: 23px; font-weight: 600; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.auth-referral-facts div:nth-child(2) dd { color: #ddb885; }
.auth-referral-transfer { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 9px 12px; align-items: end; margin: 0; }
.auth-referral-transfer label { display: grid; gap: 8px; color: #aeb8c1; font-size: 12px; }
.auth-referral-transfer input { width: 100%; min-width: 0; height: 38px; box-sizing: border-box; border: 1px solid #39434c; border-radius: 4px; padding: 0 11px; color: #eef5f1; background: #11161a; font: inherit; }
.auth-referral-transfer small { grid-column: 1 / -1; color: #8e9aa4; font-size: 11px; line-height: 1.4; }
.auth-referral-status { margin: 0; color: #9aa8b2; font-size: 12px; line-height: 1.5; }
.auth-referral-status:empty { display: none; }
.auth-referral-status.is-error { padding: 8px 10px; border-left: 2px solid #d88f72; color: #e9bb9f; background: #30251f; }
.auth-referral-status.is-success { color: #8ed3aa; }
.auth-referral-activity h3 { margin: 0 0 8px; color: #c9d2d9; font-size: 13px; font-weight: 600; }
.auth-referral-history { list-style: none; padding: 0; margin: 0; max-height: 180px; overflow-y: auto; }
.auth-referral-history li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; padding: 9px 0; border-bottom: 1px solid #29323a; color: #a8b6c0; font-size: 12px; }
.auth-referral-history li[data-status="frozen"] { color: #ddb885; }
.auth-referral-rules { margin: 0; color: #87959f; font-size: 11px; line-height: 1.5; }
@media (max-width: 640px) {
  .auth-settings-tabs { flex-wrap: nowrap; overflow-x: auto; }
  .auth-settings-tabs button { flex: 1 0 76px; }
  .auth-referral-view { padding: 18px 16px; }
  .auth-referral-heading { gap: 8px; }
  .auth-referral-heading h2 { font-size: 19px; }
  .auth-referral-heading p { font-size: 12px; }
  .auth-referral-skin { width: 40px; height: 40px; flex-basis: 40px; }
  .auth-referral-heading > .auth-referral-icon { width: 30px; height: 30px; flex-basis: 30px; }
  .auth-referral-body { gap: 16px; }
  .auth-referral-facts { gap: 8px; }
  .auth-referral-facts div + div { padding-left: 8px; }
  .auth-referral-facts dd { font-size: 20px; }
  .auth-referral-transfer { grid-template-columns: 1fr; }
}

/* moddio-ui.css */
body.in-game.game-menu-open #leaderboard,
body.in-game.game-menu-open #my-score-div,
body.in-game.game-menu-open #unit-status,
body.in-game.game-menu-open #counter,
body.in-game.game-menu-open #connection-status,
body.in-game.game-menu-open #chat-box,
body.in-game.game-menu-open #show-chat,
body.in-game.game-menu-open #chat-input-field-div,
body.in-game.game-menu-open #mobile-chat-overlay,
body.in-game.game-menu-open #mobile-chat-modal {
  display: none !important;
}

:root {
  --modal-bg-color: #282e37;
  --modal-divider-color: transparent;
  --modal-text-color: #ffffff;
  --modal-tab-active-bg-color: #536075;
  --modal-tab-inactive-bg-color: #636363;
  --modal-tab-text-color: #ffffff;
  --modal-active-tab-text-color: #ffffff;
  --modal-header-color: #ffffff;
  --modal-coin-background-color: #ffffff;
  --modal-content-bg-color: #576375;
  --purchasable-bg-color: #282e37;
  --purchasable-text-color: #ffffff;
  --purchasable-bg-color-hover: #65748b;
  --unpurchasable-bg-color: #3e4755;
}

#moddio-menu-actions {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 1000002;
  display: flex;
  align-items: flex-start;
  gap: 4px;
  font-family: Arial, sans-serif;
}

body.in-game.game-menu-open #moddio-menu-actions {
  display: none;
}

#moddio-menu-button {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  padding: 5px;
  border-color: #0062cc;
  background: #007bff;
  color: #ffffff;
}

#moddio-menu-button:hover,
#moddio-menu-button:focus,
#moddio-menu-button[aria-expanded="true"] {
  border-color: #0062cc;
  background: #0069d9;
  color: #ffffff;
  box-shadow: none;
}

#moddio-menu-tabs {
  display: flex;
  align-items: stretch;
  gap: 4px;
}

#moddio-menu-tabs[hidden] {
  display: none;
}

.nav-button {
  position: relative;
  display: none;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  padding: 5px;
  border: 1px solid transparent;
  border-radius: 0.5rem;
  background: rgb(55, 65, 81);
  color: #ffffff;
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.25rem;
}

.nav-button:hover,
.nav-button:focus-visible {
  background: rgb(55, 65, 81);
  outline: 2px solid #86b7fe;
  outline-offset: 1px;
}

.svg-style {
  width: 1.25rem;
  height: 1.25rem;
  color: #ffffff;
}

.moddio-feedback-tab {
  width: 32px;
  padding: 5px;
}

.moddio-feedback-tab > i {
  width: 1.25rem;
  height: 1.25rem;
  font-size: 1.1rem;
  line-height: 1.25rem;
}

[data-tooltip]:hover::after,
[data-tooltip]:focus-visible::after {
  position: absolute;
  top: 125%;
  left: 0;
  display: block;
  padding: 0.5em;
  border: 1px solid #111827;
  border-radius: 10px;
  background: #1f2937;
  color: #ffffff;
  content: attr(data-tooltip);
  white-space: nowrap;
}

.moddio-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000001;
  display: grid;
  place-items: center;
  padding: 16px;
  overflow-y: auto;
  background: rgba(0, 0, 0, 0.5);
  font-family: Arial, sans-serif;
}

.moddio-modal-backdrop[hidden] {
  display: none;
}

.moddio-modal {
  width: min(100%, 660px);
  max-height: calc(100vh - 32px);
  overflow: hidden;
  border: 0;
  border-radius: 10px;
  background: var(--modal-bg-color);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
  color: var(--modal-text-color);
}

.moddio-modal-sm {
  width: min(100%, 500px);
}

.moddio-modal-header,
.moddio-modal-footer {
  display: flex;
  min-height: 54px;
  align-items: center;
  padding: 12px 16px;
}

.moddio-modal-header {
  justify-content: space-between;
  border-bottom: 1px solid var(--modal-divider-color);
}

.moddio-modal-header h2 {
  margin: 0;
  color: var(--modal-header-color);
  font-size: 28px;
  font-weight: 900;
  line-height: 1.5;
}

.moddio-modal-footer {
  justify-content: flex-end;
  border-top: 1px solid #dee2e6;
}

.moddio-modal-body {
  max-height: calc(100vh - 140px);
  overflow-y: auto;
  padding: 16px;
  background: var(--modal-content-bg-color);
}

#server-disconnect-modal {
  z-index: 1000005;
}

#play-game-button .join-connecting-content {
  display: inline-flex;
  width: 100%;
  min-height: 24px;
  align-items: center;
  justify-content: center;
  column-gap: 12px;
  padding-left: 4px;
}

#play-game-button .join-connecting-spinner {
  width: 16px;
  margin: 0;
  text-align: center;
}

#server-disconnect-modal .modal-dialog {
  width: auto;
  max-width: 500px;
  margin: 0.5rem;
  pointer-events: none;
}

#server-disconnect-modal .modal-content {
  width: 100%;
  pointer-events: auto;
  border: 1px solid #bbbbbb;
  border-radius: 0.3rem;
  background: #ffffff;
  backdrop-filter: none;
  color: #212529;
  box-shadow: none;
}

#server-disconnect-modal .modal-header {
  align-items: flex-start;
  justify-content: space-between;
  padding: 1rem;
  border-bottom: 1px solid #e9ecef;
  border-top-left-radius: 0.3rem;
  border-top-right-radius: 0.3rem;
}

#server-disconnect-modal .modal-title {
  margin: 0;
  color: #212529;
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.5;
}

#server-disconnect-modal .close {
  padding: 1rem;
  margin: -1rem -1rem -1rem auto;
  border: 0;
  background: transparent;
  color: #000000;
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1;
  opacity: 0.5;
  text-shadow: 0 1px 0 #ffffff;
}

#server-disconnect-modal .close:hover,
#server-disconnect-modal .close:focus-visible {
  opacity: 0.75;
}

#server-disconnect-modal .modal-body {
  min-width: 450px;
  padding: 1rem;
  color: #212529;
  font-size: 1rem;
  line-height: 1.5;
}

#server-disconnect-modal .border-top {
  border-top-color: #dee2e6 !important;
}

#server-disconnect-modal .btn-block {
  display: block;
  width: 100%;
}

#server-disconnect-modal .btn-primary {
  border-color: #007bff;
  background-color: #007bff;
  color: #ffffff;
}

#server-disconnect-modal .btn-info {
  border-color: #17a2b8;
  background-color: #17a2b8;
  color: #ffffff;
}

@media (min-width: 576px) {
  #server-disconnect-modal .modal-dialog {
    margin: 1.75rem auto;
  }
}

@media (max-width: 575px) {
  #server-disconnect-modal .modal-body {
    min-width: 0;
  }
}

.staff-commands-panel {
  width: min(100%, 720px);
}

.staff-moderation-panel {
  width: min(100%, 900px);
  border: 1px solid #30363d;
  border-radius: 7px;
  background: #15191d;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.62);
  color: #cdd4dc;
}

.staff-feedback-panel {
  width: min(100%, 820px);
  border: 1px solid #39785d;
  border-radius: 7px;
  background: #151d1a;
  color: #e9f1eb;
}

.staff-feedback-body {
  max-height: min(720px, calc(100vh - 150px));
  overflow: auto;
}

.staff-feedback-toolbar {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 12px;
}

.staff-feedback-toolbar label { margin: 0; }

.staff-feedback-toolbar select {
  min-width: 170px;
  min-height: 38px;
  padding: 6px 9px;
  border: 1px solid #456452;
  border-radius: 5px;
  background: #102b22;
  color: #f7f8f2;
}

.staff-feedback-list {
  display: grid;
  gap: 12px;
}

.staff-feedback-entry {
  display: grid;
  gap: 8px;
  padding: 13px;
  border: 1px solid #31463a;
  border-radius: 6px;
  background: #192720;
}

.staff-feedback-entry-heading {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px 14px;
}

.staff-feedback-entry-heading time,
.staff-feedback-reviewed { color: #9fb2a6; font-size: 12px; }
.staff-feedback-email { color: #72e5b0; overflow-wrap: anywhere; }
.staff-feedback-message { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.staff-feedback-previous-reply {
  margin: 0;
  padding: 9px 11px;
  border-left: 3px solid #f5c95d;
  background: #12221b;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.staff-feedback-reply-form { display: grid; gap: 8px; }
.staff-feedback-reply-form textarea {
  width: 100%;
  min-height: 82px;
  padding: 9px;
  border: 1px solid #456452;
  border-radius: 5px;
  background: #10221a;
  color: #f7f8f2;
  font: inherit;
}
.staff-feedback-reply-form textarea:focus-visible,
.staff-feedback-toolbar select:focus-visible {
  outline: 2px solid #72e5b0;
  outline-offset: 2px;
}
.staff-feedback-reply-form button { justify-self: end; }
.staff-feedback-empty { margin: 0; padding: 18px 4px; color: #b5c4ba; }

.staff-moderation-body {
  max-height: min(680px, calc(100vh - 150px));
  overflow-y: auto;
  padding: 0;
  background: #15191d;
}

.staff-moderation-tabs {
  display: flex;
  min-height: 46px;
  align-items: stretch;
  gap: 0;
  margin: 0;
  padding: 0 14px;
  overflow-x: auto;
  border: 0;
  border-bottom: 1px solid #2b3138;
  background: #111418;
}

.staff-moderation-tab {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 16px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: #84909c;
  cursor: pointer;
  font: 600 13px/1.2 inherit;
  white-space: nowrap;
}

.staff-moderation-tab:hover,
.staff-moderation-tab:focus-visible {
  background: #1b2026;
  color: #c8d0d8;
  outline: none;
}

.staff-moderation-tab.active {
  border-bottom-color: #60b98a;
  background: #1b2026;
  color: #d7dde4;
}

.staff-moderation-view {
  min-height: 330px;
  padding: 16px;
}

.staff-moderation-view[hidden] {
  display: none;
}

#kick-players-outofgame-modal .moddio-modal-header {
  min-height: 56px;
  padding: 12px 18px;
  border-bottom: 1px solid #2b3138;
  background: #171b20;
}

#kick-players-outofgame-modal .moddio-modal-header h2 {
  color: #d7dde4;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.3;
}

#kick-players-outofgame-modal .moddio-close-button {
  color: #747f8b;
}

#kick-players-outofgame-modal .moddio-close-button:hover,
#kick-players-outofgame-modal .moddio-close-button:focus-visible {
  color: #cdd4dc;
  outline-color: #59636e;
}

#staff-moderation-status {
  min-height: 0;
  margin: 0;
  padding: 0 16px;
  background: #15191d;
}

#staff-moderation-status:not(:empty) {
  padding-top: 10px;
}

.staff-moderation-search {
  display: flex;
  width: min(100%, 430px);
  gap: 9px;
  align-items: center;
  height: 40px;
  padding: 0 11px;
  border: 1px solid #353c44;
  border-radius: 5px;
  background: #1b2026;
  color: #747f8b;
}

.staff-moderation-search:focus-within {
  border-color: #59636e;
  box-shadow: 0 0 0 2px rgba(89, 99, 110, 0.2);
}

.staff-moderation-search input {
  min-width: 0;
  flex: 1;
  border: 0;
  background: transparent;
  color: #cdd4dc;
  outline: 0;
}

.staff-moderation-search input::placeholder {
  color: #747f8b;
}

.staff-moderation-search-results {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.staff-moderation-account-controls {
  display: grid;
  gap: 10px;
  margin-top: 12px;
  border: 1px solid #30363d;
  border-radius: 5px;
  background: #111418;
}

.staff-moderation-account-controls[hidden] {
  display: none;
}

.staff-moderation-account-tabs {
  display: flex;
  min-height: 40px;
  align-items: stretch;
  margin: 0;
  padding: 0 8px;
  border: 0;
  border-bottom: 1px solid #2b3138;
  background: #171b20;
}

.staff-moderation-account-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 13px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: #84909c;
  cursor: pointer;
  font: 600 12px/1.2 inherit;
}

.staff-moderation-account-tab:hover,
.staff-moderation-account-tab:focus-visible,
.staff-moderation-account-tab.active {
  background: #1f252b;
  color: #d7dde4;
  outline: none;
}

.staff-moderation-account-tab.active {
  border-bottom-color: #60b98a;
}

.staff-moderation-duration {
  display: grid;
  grid-template-columns: auto minmax(80px, 120px) minmax(100px, 130px) auto auto;
  gap: 8px;
  align-items: center;
  padding: 0 12px 12px;
}

.staff-moderation-duration > label:first-child {
  color: #aeb7c0;
  font-size: 12px;
  font-weight: 600;
}

.staff-moderation-duration input[type="number"],
.staff-moderation-duration select {
  min-width: 0;
  height: 36px;
  padding: 5px 8px;
  border: 1px solid #384149;
  border-radius: 4px;
  background: #1b2026;
  color: #cbd3db;
}

.staff-moderation-duration input:focus,
.staff-moderation-duration select:focus {
  border-color: #60b98a;
  outline: none;
}

.staff-moderation-permanent {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #aeb7c0;
  font-size: 12px;
}

.staff-moderation-duration .btn {
  min-height: 36px;
  padding: 5px 12px;
  border-radius: 4px;
}

.staff-moderation-account {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid #30363d;
  border-radius: 6px;
  background: #1b2026;
}

.staff-moderation-account-identity {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
}

.staff-moderation-avatar {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 4px;
  background: #20262c;
  object-fit: contain;
}

.staff-moderation-account-text {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.staff-moderation-account-text strong {
  overflow: hidden;
  color: #d7dde4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-moderation-account-identity span,
.staff-moderation-empty {
  color: #84909c;
  font-size: 12px;
}

.staff-moderation-account-text .is-muted,
.staff-moderation-player-text .is-muted {
  width: fit-content;
  padding: 2px 7px;
  border: 1px solid #7d3f48;
  border-radius: 999px;
  background: #3a2227;
  color: #f0b3bb;
  font-weight: 700;
}

.staff-moderation-server-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
}

.staff-moderation-server-toolbar .btn {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  gap: 7px;
  border: 1px solid #384149;
  border-radius: 5px;
  background: #20262c;
  color: #cdd4dc;
}

.staff-moderation-server-results {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.staff-moderation-server {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 11px 12px;
  border: 1px solid #30363d;
  border-radius: 6px;
  background: #1b2026;
}

.staff-moderation-server-identity,
.staff-moderation-server-metrics {
  display: grid;
  gap: 3px;
}

.staff-moderation-server-identity strong {
  overflow: hidden;
  color: #d7dde4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-moderation-server-identity span,
.staff-moderation-server-metrics span {
  color: #84909c;
  font-size: 12px;
}

.staff-moderation-server-metrics {
  grid-template-columns: repeat(3, auto);
  align-items: center;
  gap: 12px;
  text-align: right;
}

.staff-moderation-server-metrics b {
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 11px;
}

.staff-moderation-server-metrics .is-online {
  background: #1f3b2e;
  color: #8ed5ad;
}

.staff-moderation-server-metrics .is-offline {
  background: #3a2227;
  color: #f0b3bb;
}

.staff-moderation-empty {
  margin: 0;
  padding: 16px;
  border: 1px dashed #384149;
  border-radius: 5px;
  background: #111418;
  text-align: center;
}

@media (max-width: 640px) {
  .staff-moderation-tabs {
    padding: 0 6px;
  }

  .staff-moderation-tab {
    flex: 1 0 auto;
    padding: 0 10px;
  }

  .staff-moderation-search {
    width: 100%;
  }

  .staff-moderation-duration {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .staff-moderation-duration > label:first-child,
  .staff-moderation-permanent,
  .staff-moderation-duration .btn {
    grid-column: 1 / -1;
  }

  .staff-moderation-server-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .staff-moderation-server {
    grid-template-columns: 1fr;
  }

  .staff-moderation-server-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    text-align: left;
  }
}

.staff-moderation-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 8px;
  color: #20262c;
}

.staff-moderation-table th,
.staff-moderation-table td {
  padding: 12px 10px;
  vertical-align: middle;
}

.staff-moderation-table th {
  border-bottom: 1px solid #30373e;
  color: #84909c;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.staff-moderation-table tbody td {
  border-top: 1px solid #87919b;
  border-bottom: 1px solid #87919b;
  background: #c8cdd2;
}

.staff-moderation-table tbody td:first-child {
  border-left: 1px solid #87919b;
  border-radius: 6px 0 0 6px;
}

.staff-moderation-table tbody td:last-child {
  border-right: 1px solid #87919b;
  border-radius: 0 6px 6px 0;
}

.staff-moderation-table tbody tr:hover td {
  background: #d5d9dd;
}

.staff-moderation-player {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
}

.staff-moderation-player-text {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.staff-moderation-player-text strong {
  overflow: hidden;
  color: #20262c;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-moderation-player-text span {
  color: #59636e;
  font-size: 11px;
}

.staff-moderation-table th:last-child,
.staff-moderation-table td:last-child {
  text-align: center;
}

.staff-moderation-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
}

.staff-moderation-actions .btn {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  border: 1px solid #4b5560;
  border-radius: 4px;
  background: #252b31;
  color: #c7cfd7;
  box-shadow: none;
  font-size: 12px;
}

.staff-moderation-actions .btn:hover,
.staff-moderation-actions .btn:focus-visible {
  border-color: #697580;
  background: #30373e;
  color: #ffffff;
  outline: none;
}

.staff-moderation-actions .kick-player-btn {
  border-color: #74434a;
  color: #e5b4ba;
}

.staff-moderation-actions .ban-ip-btn {
  border-color: #5f5540;
  color: #d7c698;
}

.staff-moderation-actions .ban-chat-btn {
  border-color: #38576c;
  color: #aad0e6;
}

.staff-moderation-actions .warn-player-btn {
  border-color: #515862;
  color: #c9d0d7;
}

.staff-moderation-actions .btn:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.staff-moderation-account > .ban-chat-btn {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  gap: 7px;
  padding: 6px 11px;
  border: 1px solid #38576c;
  border-radius: 4px;
  background: #252b31;
  color: #aad0e6;
}

.source-warning-message {
  color: #222222;
}

.source-warning-message p {
  margin: 0;
}

.staff-role-label {
  margin-left: auto;
  margin-right: 12px;
  font-size: 13px;
  font-weight: 700;
}

.staff-commands-body,
.staff-command-form {
  display: grid;
  gap: 12px;
}
.staff-event-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 38px;
  align-items: center;
  gap: 6px;
  margin: 12px 0;
}
.staff-event-controls label { grid-column: 1 / -1; margin: 0; }
.staff-event-controls select { width: 100%; min-width: 0; }
.staff-event-controls button { width: 38px; height: 38px; padding: 0; }

.staff-command-help {
  color: #aeb7c0;
}

.staff-command-help > section {
  color: #aeb7c0;
}

.staff-moderation-commands {
  display: grid;
  gap: 16px;
}

.staff-moderation-commands .staff-command-help {
  max-height: 300px;
  overflow-y: auto;
  padding: 14px;
  border: 1px solid #30373e;
  border-radius: 5px;
  background: #111418;
}

.staff-command-entry {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  gap: 8px;
}

.staff-command-entry input {
  min-width: 0;
  height: 42px;
  padding: 8px 10px;
  border: 1px solid #384149;
  border-radius: 5px;
  background: #11161a;
  color: #cbd3db;
}

.staff-command-entry input:focus {
  border-color: #60b98a;
  box-shadow: 0 0 0 2px rgba(96, 185, 138, 0.2);
  outline: none;
}

.staff-command-entry button {
  width: 42px;
  height: 42px;
  padding: 0;
}

.braains-quests-panel {
  width: min(100%, 620px);
}

.braains-quests-note {
  margin: 0 0 16px;
  text-align: center;
}

.braains-quests-list {
  display: grid;
  gap: 8px;
}

.braains-quest-row {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 9px 10px;
  background: rgba(40, 46, 55, 0.72);
}

.braains-quest-row img {
  width: 16px;
  height: 16px;
}

.braains-quest-status {
  color: #99f000;
  white-space: nowrap;
}

.braains-quests-footer-image {
  display: block;
  width: min(100%, 300px);
  height: auto;
  margin: 18px auto 0;
}

.moddio-close-button {
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #ffffff;
  cursor: pointer;
  font-size: 27px;
  line-height: 1;
}

.moddio-close-button:hover,
.moddio-close-button:focus-visible {
  color: #ffffff;
  outline: 2px solid #86b7fe;
  outline-offset: 1px;
}

.moddio-balance {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  padding: 5px 10px;
  border-radius: 20px;
  background: var(--modal-coin-background-color);
  color: #282e37;
  font-size: 14px;
  font-weight: 600;
}

.moddio-coin-icon {
  display: inline-block;
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  object-fit: contain;
  opacity: 1;
  visibility: visible;
}

.moddio-skin-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  min-height: 0;
}

.moddio-skin-card {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 150px;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 4px;
  border: 6px solid var(--modal-bg-color);
  border-radius: 10px;
  background: #d5ad61;
  color: var(--purchasable-text-color);
  text-align: center;
}

.moddio-skin-card.is-owned {
  border-color: var(--modal-bg-color);
  background: #955f3b;
}

.moddio-skin-card.is-equipped {
  border-color: #254edb;
}

.moddio-skin-image {
  width: 100px;
  height: 100px;
  margin: auto 0 8px;
  object-fit: contain;
  image-rendering: auto;
}

.moddio-skin-card h3 {
  display: none;
  margin: 0;
  color: var(--purchasable-text-color);
  font-size: 14px;
  font-weight: 600;
}

.moddio-skin-shop-modal {
  display: flex;
  width: min(100%, 980px);
  max-height: min(700px, calc(100vh - 32px));
  flex-direction: column;
}

.moddio-skin-shop-modal > .moddio-skin-shop-body {
  min-height: 0;
}

.moddio-wallet-modal {
  width: min(100%, 680px);
}

.moddio-wallet-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  padding: 0 16px 12px;
  background: var(--modal-bg-color);
}

.moddio-wallet-tab {
  min-height: 38px;
  border: 0;
  border-radius: 4px;
  background: var(--modal-tab-inactive-bg-color);
  color: var(--modal-tab-text-color);
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
}

.moddio-wallet-tab.is-active {
  background: var(--modal-tab-active-bg-color);
  color: var(--modal-active-tab-text-color);
}

.moddio-wallet-tab:focus-visible {
  outline: 2px solid #86b7fe;
  outline-offset: 1px;
}

.moddio-wallet-body {
  min-height: 360px;
}

.moddio-wallet-packages {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.moddio-wallet-package {
  display: grid;
  min-height: 118px;
  grid-template-columns: 46px minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: center;
  gap: 2px 10px;
  padding: 14px;
  border: 5px solid var(--modal-bg-color);
  border-radius: 8px;
  background: #d5ad61;
  color: #ffffff;
  cursor: pointer;
  text-align: left;
}

.moddio-wallet-package:hover,
.moddio-wallet-package:focus-visible {
  border-color: #254edb;
  outline: none;
}

.moddio-wallet-package img {
  width: 42px;
  height: 42px;
  grid-row: 1 / 3;
  object-fit: contain;
}

.moddio-wallet-package strong {
  align-self: end;
  font-size: 20px;
  line-height: 1.2;
}

.moddio-wallet-package span {
  align-self: start;
  font-size: 14px;
  font-weight: 700;
}

.moddio-wallet-intent {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 6px;
  background: var(--modal-bg-color);
}

.moddio-wallet-intent[hidden] {
  display: none;
}

.moddio-wallet-intent-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.moddio-wallet-intent label,
.moddio-wallet-intent-summary span {
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
  font-weight: 600;
}

.moddio-wallet-intent-summary strong {
  font-size: 18px;
}

.moddio-wallet-claim-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  gap: 6px;
}

.moddio-wallet-claim-row input {
  min-width: 0;
  height: 38px;
  padding: 0 10px;
  border: 1px solid #929ba7;
  border-radius: 4px;
  background: #ffffff;
  color: #212529;
  font: 700 13px/1.2 monospace;
}

.moddio-wallet-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.moddio-wallet-actions .moddio-button {
  flex: 1 1 180px;
  text-decoration: none;
}

.moddio-wallet-donation {
  display: grid;
  min-height: 290px;
  place-items: center;
  align-content: center;
  gap: 10px;
  text-align: center;
}

.moddio-wallet-donation > i {
  color: #dc3545;
  font-size: 44px;
}

.moddio-wallet-donation > strong {
  font-size: 22px;
}

.moddio-wallet-donation > span {
  max-width: 420px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
}

.moddio-wallet-donation .moddio-button {
  margin-top: 8px;
  text-decoration: none;
}

.moddio-wallet-history {
  display: grid;
  gap: 8px;
}

.moddio-wallet-history-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 16px;
  padding: 10px 12px;
  border-radius: 4px;
  background: var(--modal-bg-color);
}

.moddio-wallet-history-row span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
}

.moddio-wallet-history-row strong:last-child {
  grid-row: 1 / 3;
  grid-column: 2;
  align-self: center;
  text-transform: capitalize;
}

@media (max-width: 575px) {
  .moddio-wallet-packages {
    grid-template-columns: 1fr;
  }

  .moddio-wallet-body {
    min-height: 0;
  }
}

/* Braains wallet follows the newer account-settings visual system. */
#modd-wallet-modal {
  background: rgba(4, 7, 10, 0.78);
  backdrop-filter: blur(8px);
}

#modd-wallet-modal .moddio-wallet-modal {
  width: min(100%, 860px);
  min-height: 520px;
  border: 1px solid #30363d;
  border-radius: 7px;
  background: #15191d;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.62);
  color: #cdd4dc;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

#modd-wallet-modal .moddio-modal-header {
  min-height: 64px;
  gap: 14px;
  padding: 12px 18px;
  border-bottom: 1px solid #2b3138;
  background: #171b20;
}

.moddio-wallet-heading {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 11px;
}

.moddio-wallet-mark {
  display: grid;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  place-items: center;
  border: 1px solid #353c44;
  border-radius: 7px;
  background: #20262c;
}

.moddio-wallet-mark img {
  width: 24px;
  height: 24px;
}

#modd-wallet-modal .moddio-wallet-heading h2 {
  max-width: none;
  height: auto;
  padding: 0;
  color: #dce2e8;
  font-size: 18px;
  font-weight: 650;
  line-height: 1.25;
}

.moddio-wallet-heading p {
  margin: 2px 0 0;
  color: #7f8a96;
  font-size: 12px;
}

#modd-wallet-modal .moddio-balance {
  margin-left: auto;
  padding: 6px 10px;
  border: 1px solid #353c44;
  border-radius: 6px;
  background: #111418;
  color: #d7dde4;
}

#modd-wallet-modal .moddio-close-button {
  flex: 0 0 32px;
  border-radius: 4px;
  color: #747f8b;
}

#modd-wallet-modal .moddio-close-button:hover,
#modd-wallet-modal .moddio-close-button:focus-visible {
  background: #2b2f35;
  color: #ffffff;
  outline: none;
}

.moddio-wallet-shell {
  display: grid;
  grid-template-columns: 184px minmax(0, 1fr);
  min-height: 456px;
}

#modd-wallet-modal .moddio-wallet-tabs {
  display: flex;
  grid-template-columns: none;
  flex-direction: column;
  gap: 4px;
  padding: 16px 10px;
  border-right: 1px solid #292f35;
  background: #111418;
}

#modd-wallet-modal .moddio-wallet-tab {
  display: flex;
  min-height: 42px;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-left: 2px solid transparent;
  border-radius: 4px;
  background: transparent;
  color: #8e99a5;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
}

#modd-wallet-modal .moddio-wallet-tab i {
  width: 16px;
  color: #718078;
  text-align: center;
}

#modd-wallet-modal .moddio-wallet-tab:hover,
#modd-wallet-modal .moddio-wallet-tab:focus-visible {
  background: #1b2026;
  color: #c8d0d8;
  outline: none;
}

#modd-wallet-modal .moddio-wallet-tab.is-active {
  border-color: #2d343b;
  border-left-color: #60b98a;
  background: #20262c;
  color: #d7e4dc;
  box-shadow: none;
}

#modd-wallet-modal .moddio-wallet-tab.is-active i {
  color: #70c899;
}

#modd-wallet-modal .moddio-wallet-tab[aria-selected="true"] {
  border-right-color: #384149;
}

#modd-wallet-modal .moddio-wallet-body {
  min-height: 456px;
  max-height: calc(100vh - 112px);
  padding: 26px 30px;
  background: #15191d;
}

.moddio-wallet-view-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

.moddio-wallet-view-heading h3 {
  margin: 0;
  color: #dce2e8;
  font-size: 22px;
  font-weight: 650;
  line-height: 1.2;
}

.moddio-wallet-view-heading p {
  max-width: 520px;
  margin: 6px 0 0;
  color: #8d98a4;
  font-size: 13px;
  line-height: 1.45;
}

.moddio-wallet-secure {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  border: 1px solid #30503e;
  border-radius: 5px;
  background: #17261e;
  color: #7fd5a3;
  font-size: 11px;
  font-weight: 600;
}

#modd-wallet-modal .moddio-wallet-packages {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

#modd-wallet-modal .moddio-wallet-package {
  min-height: 104px;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  gap: 5px 12px;
  padding: 15px 16px;
  border: 1px solid #30373e;
  border-radius: 6px;
  background: #1c2126;
  color: #d7dde4;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025);
}

#modd-wallet-modal .moddio-wallet-package .moddio-wallet-package-mark {
  display: grid;
  width: 38px;
  height: 38px;
  grid-row: 1 / 3;
  place-items: center;
  border: 1px solid #3d4b43;
  border-radius: 6px;
  background: #17231c;
  color: #70c899;
  font-size: 16px;
}

#modd-wallet-modal .moddio-wallet-package-mark i {
  color: inherit;
}

#modd-wallet-modal .moddio-wallet-package-details {
  display: grid;
  min-width: 0;
  grid-column: 2;
  grid-row: 1 / 3;
  gap: 5px;
  align-content: center;
}

#modd-wallet-modal .moddio-wallet-package:hover,
#modd-wallet-modal .moddio-wallet-package:focus-visible {
  border-color: #4b6658;
  background: #20272b;
  box-shadow: inset 0 0 0 1px rgba(96, 185, 138, 0.2);
}

#modd-wallet-modal .moddio-wallet-package:disabled {
  cursor: default;
  opacity: 0.48;
}

.moddio-wallet-tab:disabled,
[data-wallet-picker]:disabled {
  cursor: default;
  opacity: 0.45;
}

.moddio-button[aria-disabled="true"] {
  pointer-events: none;
  opacity: 0.55;
}

#modd-wallet-modal .moddio-wallet-package strong {
  align-self: end;
  color: #e3e8ed;
  font-size: 21px;
}

#modd-wallet-modal .moddio-wallet-package span {
  align-self: start;
  color: #8f9aa5;
  font-size: 12px;
  font-weight: 500;
}

#modd-wallet-modal .moddio-wallet-package b {
  grid-row: 1 / 3;
  grid-column: 3;
  align-self: center;
  padding: 7px 9px;
  border: 1px solid #3d4b43;
  border-radius: 5px;
  background: #17231c;
  color: #8fd8ae;
  font-size: 13px;
}

.moddio-wallet-availability {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  padding: 12px 14px;
  border: 1px solid #504936;
  border-radius: 6px;
  background: #252116;
  color: #d8c98d;
}

.moddio-wallet-availability[hidden] {
  display: none;
}

.moddio-wallet-availability > i {
  color: #d8b75d;
  font-size: 17px;
}

.moddio-wallet-availability div {
  display: grid;
  gap: 2px;
}

.moddio-wallet-availability strong {
  font-size: 13px;
}

.moddio-wallet-availability span {
  color: #a99e77;
  font-size: 12px;
}

#modd-wallet-modal .moddio-wallet-intent {
  margin-top: 16px;
  padding: 15px;
  border-color: #30373e;
  border-radius: 6px;
  background: #1b2025;
}

#modd-wallet-modal .moddio-wallet-intent-summary {
  padding-bottom: 10px;
  border-bottom: 1px solid #30373e;
}

#modd-wallet-modal .moddio-wallet-intent label,
#modd-wallet-modal .moddio-wallet-intent-summary span {
  color: #aeb7c0;
}

#modd-wallet-modal .moddio-wallet-intent-summary strong {
  color: #e1eee7;
}

#modd-wallet-modal .moddio-wallet-claim-row input {
  border-color: #3a424b;
  background: #11161a;
  color: #d7dde4;
}

#modd-wallet-modal .moddio-wallet-actions .moddio-button.btn-success,
#modd-wallet-modal .moddio-wallet-donation .moddio-button.btn-success {
  border-color: #408b65;
  background: #347456;
  color: #e1eee7;
}

#modd-wallet-modal .moddio-wallet-actions .moddio-button.btn-light,
#modd-wallet-modal .moddio-wallet-actions .moddio-button.btn-secondary {
  border-color: #384149;
  background: #20262c;
  color: #aeb7c0;
}

#modd-wallet-modal .moddio-wallet-actions .moddio-button:not(:disabled):hover,
#modd-wallet-modal .moddio-wallet-actions .moddio-button:not(:disabled):focus-visible,
#modd-wallet-modal .moddio-wallet-donation .moddio-button:not(:disabled):hover,
#modd-wallet-modal .moddio-wallet-donation .moddio-button:not(:disabled):focus-visible {
  border-color: #60b98a;
  background: #408b65;
  color: #ffffff;
  filter: none;
  outline: 2px solid rgba(96, 185, 138, 0.25);
  outline-offset: 1px;
}

#modd-wallet-modal .moddio-wallet-donation {
  min-height: 300px;
  grid-template-columns: 56px minmax(0, 1fr);
  place-items: initial;
  align-content: center;
  gap: 12px 16px;
  text-align: left;
}

.moddio-wallet-donation-mark {
  display: grid;
  width: 56px;
  height: 56px;
  grid-row: 1 / 4;
  place-items: center;
  border: 1px solid #30503e;
  border-radius: 7px;
  background: #17261e;
  color: #70c899;
  font-size: 22px;
}

#modd-wallet-modal .moddio-wallet-donation > div > strong {
  color: #dce2e8;
  font-size: 20px;
}

#modd-wallet-modal .moddio-wallet-donation > div > span {
  display: block;
  max-width: 520px;
  margin-top: 5px;
  color: #8d98a4;
  font-size: 13px;
  line-height: 1.45;
}

.moddio-wallet-payment-methods {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.moddio-wallet-payment-methods span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  border: 1px solid #384149;
  border-radius: 5px;
  background: #20262c;
  color: #9da8b3;
  font-size: 11px;
}

#modd-wallet-modal .moddio-wallet-donation .moddio-button {
  width: max-content;
  margin-top: 2px;
}

#modd-wallet-modal .moddio-wallet-history-row {
  padding: 12px 14px;
  border: 1px solid #30373e;
  border-radius: 6px;
  background: #1c2126;
}

@media (max-width: 680px) {
  #modd-wallet-modal {
    align-items: end;
    padding: 0;
  }

  #modd-wallet-modal .moddio-wallet-modal {
    width: 100%;
    max-height: 94vh;
    min-height: 0;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 7px 7px 0 0;
  }

  .moddio-wallet-shell {
    display: block;
    min-height: 0;
  }

  #modd-wallet-modal .moddio-wallet-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 8px 10px;
    border-right: 0;
    border-bottom: 1px solid #292f35;
  }

  #modd-wallet-modal .moddio-wallet-tab {
    justify-content: center;
    padding: 9px 6px;
    border-left: 1px solid transparent;
  }

  #modd-wallet-modal .moddio-wallet-tab.is-active {
    border-color: #2d343b;
    border-bottom-color: #60b98a;
  }

  #modd-wallet-modal .moddio-wallet-body {
    min-height: 0;
    max-height: calc(94vh - 120px);
    padding: 20px 16px 24px;
  }

  #modd-wallet-modal .moddio-wallet-packages {
    grid-template-columns: 1fr;
  }

  .moddio-wallet-view-heading {
    display: block;
  }

  .moddio-wallet-secure {
    margin-top: 10px;
  }
}

#coin-shop-modal .moddio-wallet-legal-consent {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 9px;
  align-items: start;
  margin: 14px 0 4px;
  color: #9fa9b5;
  font-size: 12px;
  line-height: 1.5;
}

#coin-shop-modal .moddio-wallet-legal-consent input {
  width: 16px;
  height: 16px;
  margin: 1px 0 0;
  accent-color: #60b98a;
}

#coin-shop-modal .moddio-wallet-legal-consent a {
  color: #86efac;
}

/* Braains Io original wallet layout with the account-settings color system. */
#coin-shop-modal {
  z-index: 25000;
  align-items: center;
  background: rgba(4, 7, 10, 0.78);
  backdrop-filter: blur(8px);
}

#coin-shop-modal .moddio-wallet-modal {
  width: min(100%, 760px);
  min-width: min(500px, calc(100vw - 32px));
  min-height: 0;
  border: 1px solid #30363d;
  border-radius: 7px;
  background: #15191d;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.62);
  color: #cdd4dc;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

#coin-shop-modal .moddio-modal-header {
  min-height: 58px;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid #2b3138;
  background: #171b20;
}

#coin-shop-modal .modal-title {
  margin: 0;
  color: #d7dde4;
  font-size: 20px;
  font-weight: 500;
  line-height: 1.5;
}

#coin-shop-modal .moddio-balance {
  margin-left: auto;
  padding: 4px 9px;
  border: 1px solid #353c44;
  border-radius: 6px;
  background: #111418;
  color: #d7dde4;
}

#coin-shop-modal .moddio-close-button {
  flex: 0 0 32px;
  color: #747f8b;
  opacity: 1;
}

#coin-shop-modal .moddio-close-button:hover,
#coin-shop-modal .moddio-close-button:focus-visible {
  background: #2b2f35;
  color: #ffffff;
  opacity: 1;
  outline: none;
}

#coin-shop-modal .moddio-wallet-shell {
  display: block;
  min-height: 0;
  background: #15191d;
}

#coin-shop-modal .moddio-wallet-tabs {
  display: flex;
  flex-direction: row;
  gap: 0;
  margin: 0;
  padding: 10px 16px 0;
  border: 0;
  border-bottom: 1px solid #292f35;
  background: #111418;
}

#coin-shop-modal .moddio-wallet-tab {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-bottom: -1px;
  padding: 8px 14px;
  border: 1px solid transparent;
  border-radius: 4px 4px 0 0;
  background: transparent;
  color: #8e99a5;
  font-size: 14px;
  font-weight: 600;
}

#coin-shop-modal .moddio-wallet-tab:hover,
#coin-shop-modal .moddio-wallet-tab:focus-visible {
  border-color: #2d343b #2d343b #292f35;
  background: #1b2026;
  color: #c8d0d8;
  outline: 0;
}

#coin-shop-modal .moddio-wallet-tab.is-active {
  border-color: #2d343b #2d343b #60b98a;
  background: #20262c;
  color: #d7e4dc;
}

#coin-shop-modal .moddio-wallet-body {
  min-height: 0;
  max-height: calc(100vh - 170px);
  padding: 16px;
  background: #15191d;
  color: #cdd4dc;
}

#coin-shop-modal .moddio-coin-shop-view,
#coin-shop-modal .coin-offers {
  display: block;
}

#coin-shop-modal .moddio-wallet-packages {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

#coin-shop-modal .moddio-wallet-package {
  position: relative;
  display: grid;
  min-height: 88px;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 2px 10px;
  padding: 12px;
  border: 1px solid #30373e;
  border-radius: 6px;
  background: #1c2126;
  color: #d7dde4;
  box-shadow: none;
  cursor: pointer;
  text-align: left;
}

#coin-shop-modal .moddio-wallet-package:hover,
#coin-shop-modal .moddio-wallet-package:focus-visible {
  border-color: #4b6658;
  background: #20272b;
  box-shadow: inset 0 0 0 1px rgba(96, 185, 138, 0.2);
  outline: 0;
}

#coin-shop-modal .moddio-wallet-package:disabled {
  cursor: default;
  opacity: 0.65;
}

#coin-shop-modal .moddio-wallet-package-mark {
  display: grid;
  width: 38px;
  height: 38px;
  grid-row: 1 / 3;
  place-items: center;
}

#coin-shop-modal .moddio-wallet-package-mark img {
  width: 34px;
  height: 34px;
  object-fit: contain;
}

#coin-shop-modal .moddio-wallet-package-details {
  display: grid;
  min-width: 0;
  grid-column: 2;
  grid-row: 1 / 3;
  gap: 2px;
  align-content: center;
}

#coin-shop-modal .moddio-wallet-package strong {
  align-self: end;
  color: #e3e8ed;
  font-size: 18px;
  line-height: 1.2;
}

#coin-shop-modal .moddio-wallet-package span {
  align-self: start;
  color: #8f9aa5;
  font-size: 13px;
  font-weight: 400;
}

#coin-shop-modal .moddio-wallet-package b {
  grid-column: 3;
  grid-row: 1 / 3;
  align-self: center;
  min-width: 58px;
  padding: 6px 8px;
  border: 1px solid #3d4b43;
  border-radius: 4px;
  background: #17231c;
  color: #8fd8ae;
  font-size: 13px;
  font-weight: 400;
  text-align: center;
}

#coin-shop-modal .moddio-wallet-package-price {
  display: grid;
  grid-column: 3;
  grid-row: 1 / 3;
  gap: 2px;
  justify-items: end;
}

#coin-shop-modal .moddio-wallet-package-price b {
  grid-column: auto;
  grid-row: auto;
}

#coin-shop-modal .moddio-wallet-package-price s {
  color: #75808b;
  font-size: 11px;
}

#coin-shop-modal .moddio-wallet-package-badge {
  width: max-content;
  padding: 2px 5px;
  border: 1px solid #4b6958;
  border-radius: 3px;
  background: #1a2b22;
  color: #8fd8ae;
  font-size: 10px;
  font-weight: 700;
  line-height: 1.2;
}

#coin-shop-modal .moddio-wallet-promo {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid #30373e;
  border-radius: 5px;
  background: #191e23;
}

#coin-shop-modal .moddio-wallet-promo label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0;
  color: #cdd4dc;
  font-size: 12px;
  font-weight: 600;
}

#coin-shop-modal .moddio-wallet-promo label span {
  color: #7f8b96;
  font-size: 11px;
  font-weight: 400;
}

#coin-shop-modal .moddio-wallet-promo-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

#coin-shop-modal .moddio-wallet-promo-row input {
  min-width: 0;
  height: 36px;
  padding: 0 10px;
  border: 1px solid #384149;
  border-radius: 4px;
  background: #111418;
  color: #e1e6eb;
  font-size: 13px;
  text-transform: uppercase;
}

#coin-shop-modal .moddio-wallet-promo-row input:focus {
  border-color: #60b98a;
  outline: 0;
}

#coin-shop-modal .moddio-wallet-promo-row .moddio-button {
  min-width: 76px;
  height: 36px;
}

#coin-shop-modal #modd-wallet-promo-status {
  min-height: 15px;
  margin: 0;
  color: #8f9aa5;
  font-size: 11px;
}

#coin-shop-modal #modd-wallet-promo-status.is-success {
  color: #8fd8ae;
}

#coin-shop-modal #modd-wallet-promo-status.is-error {
  color: #df8d8d;
}

#coin-shop-modal .moddio-wallet-availability {
  margin-bottom: 12px;
  border-color: #504936;
  background: #252116;
  color: #d8c98d;
}

#coin-shop-modal .moddio-wallet-availability span,
#coin-shop-modal .moddio-wallet-availability > i {
  color: #d8b75d;
}

#coin-shop-modal .moddio-wallet-intent {
  margin-top: 14px;
  border-color: #30373e;
  background: #1b2025;
  color: #cbd3db;
}

#coin-shop-modal .moddio-wallet-intent label,
#coin-shop-modal .moddio-wallet-intent-summary span,
#coin-shop-modal .moddio-wallet-intent-summary strong {
  color: #aeb7c0;
}

#coin-shop-modal .moddio-wallet-actions .moddio-button.btn-success,
#coin-shop-modal .moddio-wallet-donation .moddio-button.btn-success {
  border-color: #408b65;
  background: #347456;
  color: #e1eee7;
}

#coin-shop-modal .moddio-wallet-actions .moddio-button.btn-light,
#coin-shop-modal .moddio-wallet-actions .moddio-button.btn-secondary {
  border-color: #384149;
  background: #20262c;
  color: #aeb7c0;
}

#coin-shop-modal .moddio-wallet-view-heading h3,
#coin-shop-modal .moddio-wallet-donation > div > strong {
  color: #dce2e8;
}

#coin-shop-modal .moddio-wallet-view-heading p,
#coin-shop-modal .moddio-wallet-donation > div > span {
  color: #8d98a4;
}

#coin-shop-modal .moddio-wallet-donation {
  min-height: 300px;
  grid-template-columns: 56px minmax(0, 1fr);
  place-items: initial;
  align-content: center;
  gap: 12px 16px;
  text-align: left;
}

#coin-shop-modal .moddio-wallet-donation-mark {
  grid-row: 1 / 4;
  border-color: #30503e;
  background: #17261e;
  color: #70c899;
}

#coin-shop-modal .moddio-wallet-donation > div {
  min-width: 0;
}

#coin-shop-modal .moddio-wallet-donation > div > strong,
#coin-shop-modal .moddio-wallet-donation > div > span {
  display: block;
}

#coin-shop-modal .moddio-wallet-donation > div > span {
  max-width: 520px;
  margin-top: 5px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

#coin-shop-modal .moddio-wallet-payment-methods {
  justify-content: flex-start;
}

#coin-shop-modal .moddio-wallet-donation .moddio-button {
  width: max-content;
  margin-top: 2px;
}

#coin-shop-modal .moddio-wallet-payment-methods span,
#coin-shop-modal .moddio-wallet-history-row {
  border: 1px solid #384149;
  background: #20262c;
  color: #9da8b3;
}

#coin-shop-modal .moddio-wallet-history {
  max-height: min(460px, calc(100vh - 250px));
  overflow-y: auto;
  padding-right: 3px;
}

#coin-shop-modal .moddio-wallet-history-row {
  grid-template-columns: 46px minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 3px 10px;
  min-height: 66px;
  padding: 9px 11px;
}

#coin-shop-modal .moddio-wallet-history-image {
  width: 42px;
  height: 42px;
  grid-row: 1 / 3;
  border-radius: 4px;
  background: #15191d;
  object-fit: contain;
}

#coin-shop-modal .moddio-wallet-history-details {
  display: grid;
  min-width: 0;
  gap: 2px;
}

#coin-shop-modal .moddio-wallet-history-details strong {
  overflow: hidden;
  color: #dce2e8;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#coin-shop-modal .moddio-wallet-history-details span {
  color: #87929d;
  font-size: 11px;
}

#coin-shop-modal .moddio-wallet-history-price {
  display: inline-flex;
  grid-column: 3;
  grid-row: 1 / 3;
  align-items: center;
  gap: 5px;
  color: #9cd7b5;
  font-size: 12px;
}

#coin-shop-modal .moddio-wallet-history-price img {
  width: 16px;
  height: 16px;
  object-fit: contain;
}

#coin-shop-modal .moddio-wallet-modal {
  width: min(100%, 980px);
}

#coin-shop-modal .moddio-wallet-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding-top: 8px;
}

#coin-shop-modal .moddio-wallet-tab {
  min-width: 0;
  padding-right: 10px;
  padding-left: 10px;
}

#coin-shop-modal .moddio-wallet-commands {
  display: flex;
  gap: 6px;
  justify-content: flex-end;
  padding: 7px 16px;
  border-bottom: 1px solid #292f35;
  background: #15191d;
}

#coin-shop-modal .moddio-wallet-command {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  border: 1px solid #384149;
  border-radius: 4px;
  background: #20262c;
  color: #b8c1ca;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
}

#coin-shop-modal .moddio-wallet-command:hover,
#coin-shop-modal .moddio-wallet-command:focus-visible {
  border-color: #5b6c60;
  background: #263029;
  color: #e1eee7;
  outline: 0;
}

#coin-shop-modal .moddio-wallet-command:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

#coin-shop-modal .moddio-wallet-body {
  min-height: 360px;
  max-height: min(620px, calc(100vh - 192px));
}

#coin-shop-modal .moddio-wallet-view-heading {
  display: flex;
  min-height: 36px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

#coin-shop-modal .moddio-wallet-view-heading h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0;
}

#coin-shop-modal .moddio-wallet-period-controls,
#coin-shop-modal .moddio-wallet-transaction-controls {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 6px;
}

#coin-shop-modal .moddio-wallet-period-controls label,
#coin-shop-modal .moddio-wallet-transaction-controls label {
  color: #89949f;
  font-size: 11px;
  font-weight: 600;
}

#coin-shop-modal .moddio-wallet-period-controls select,
#coin-shop-modal .moddio-wallet-transaction-controls select,
#coin-shop-modal .moddio-wallet-transaction-controls input {
  height: 32px;
  min-width: 0;
  padding: 4px 7px;
  border: 1px solid #384149;
  border-radius: 4px;
  background: #111418;
  color: #dce2e8;
  font-size: 12px;
}

#coin-shop-modal .moddio-wallet-transaction-controls select {
  width: 165px;
}

#coin-shop-modal .moddio-wallet-table-wrap {
  max-width: 100%;
  overflow: auto;
  border: 1px solid #30373e;
  border-radius: 5px;
}

#coin-shop-modal .moddio-wallet-table {
  width: 100%;
  min-width: 780px;
  border-collapse: collapse;
  table-layout: auto;
  color: #cbd3db;
  font-size: 12px;
}

#coin-shop-modal .moddio-wallet-summary-table {
  min-width: 930px;
  table-layout: fixed;
}

#coin-shop-modal .moddio-wallet-table th,
#coin-shop-modal .moddio-wallet-table td {
  min-width: 88px;
  padding: 8px 9px;
  border-right: 1px solid #30373e;
  border-bottom: 1px solid #30373e;
  text-align: left;
  vertical-align: middle;
  white-space: nowrap;
}

#coin-shop-modal .moddio-wallet-summary-table th,
#coin-shop-modal .moddio-wallet-summary-table td {
  text-align: center;
  white-space: normal;
}

#coin-shop-modal .moddio-wallet-table th {
  background: #20262c;
  color: #aeb8c2;
  font-size: 11px;
  font-weight: 700;
}

#coin-shop-modal .moddio-wallet-table thead tr:first-child th {
  background: #252c32;
  color: #dbe2e8;
}

#coin-shop-modal .moddio-wallet-table tbody tr:nth-child(even) td {
  background: #191e23;
}

#coin-shop-modal .moddio-wallet-table tbody tr:hover td {
  background: #222a30;
}

#coin-shop-modal .moddio-wallet-table th:last-child,
#coin-shop-modal .moddio-wallet-table td:last-child {
  border-right: 0;
}

#coin-shop-modal .moddio-wallet-table tbody tr:last-child td {
  border-bottom: 0;
}

#coin-shop-modal .moddio-wallet-table-empty {
  height: 94px;
  color: #7f8a96;
  text-align: center;
}

#coin-shop-modal .moddio-wallet-table .is-revenue {
  color: #8fd8ae;
  font-weight: 700;
}

#coin-shop-modal .moddio-wallet-table .is-expense {
  color: #e59b9b;
  font-weight: 700;
}

#coin-shop-modal #modd-wallet-report-status {
  min-height: 18px;
  margin: 8px 0 0;
  font-size: 11px;
}

@media (max-width: 575px) {
  #coin-shop-modal {
    align-items: center;
    padding: 8px;
  }

  #coin-shop-modal .moddio-wallet-modal {
    min-width: 0;
  }

  #coin-shop-modal .moddio-wallet-tabs {
    display: flex;
    grid-template-columns: none;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-right: 8px;
    padding-left: 8px;
  }

  #coin-shop-modal .moddio-wallet-tab {
    flex: 0 0 auto;
    min-width: 108px;
    white-space: nowrap;
  }

  #coin-shop-modal .moddio-wallet-commands {
    padding-right: 8px;
    padding-left: 8px;
  }

  #coin-shop-modal .moddio-wallet-view-heading,
  #coin-shop-modal .moddio-wallet-transaction-controls {
    align-items: stretch;
    flex-direction: column;
  }

  #coin-shop-modal .moddio-wallet-period-controls {
    align-self: stretch;
  }

  #coin-shop-modal .moddio-wallet-period-controls select {
    flex: 1 1 0;
  }

  #coin-shop-modal .moddio-wallet-transaction-controls select,
  #coin-shop-modal .moddio-wallet-transaction-controls input {
    width: 100%;
  }

  #coin-shop-modal .moddio-wallet-tab {
    padding-right: 10px;
    padding-left: 10px;
  }

  #coin-shop-modal .moddio-wallet-body {
    padding: 12px;
  }

  #coin-shop-modal .moddio-wallet-packages {
    grid-template-columns: 1fr;
  }

  #coin-shop-modal .moddio-wallet-promo label {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
  }

  #coin-shop-modal .moddio-wallet-donation {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
    place-items: center;
    gap: 12px;
    padding: 4px 0 8px;
    text-align: center;
  }

  #coin-shop-modal .moddio-wallet-donation-mark {
    grid-row: auto;
  }

  #coin-shop-modal .moddio-wallet-payment-methods {
    justify-content: center;
  }

  #coin-shop-modal .moddio-wallet-donation .moddio-button {
    width: min(100%, 240px);
  }
}

.auth-wallet-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 16px 18px 0;
  border-top: 1px solid #30373e;
  border-right: 1px solid #30373e;
  border-left: 1px solid #30373e;
  border-bottom: 1px solid #292f35;
  border-radius: 5px 5px 0 0;
  background: #111418;
}

.auth-wallet-tab {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border: 1px solid #30373e;
  border-bottom: 2px solid transparent;
  border-radius: 4px 4px 0 0;
  background: transparent;
  color: #8e99a5;
  cursor: pointer;
  font: 600 13px/1.25 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-wallet-tab:hover,
.auth-wallet-tab:focus-visible {
  background: #1b2026;
  color: #d7e4dc;
  outline: none;
}

.auth-wallet-tab.is-active {
  border-color: #4b6658;
  border-bottom-color: #60b98a;
  background: #20262c;
  color: #d7e4dc;
}

.auth-wallet-body {
  min-width: 0;
  min-height: 390px;
  padding: 24px 28px;
  overflow: auto;
  border: 1px solid #30373e;
  border-top: 0;
  border-radius: 0 0 5px 5px;
  background: #15191d;
}

.auth-wallet-body .moddio-wallet-view-heading {
  display: flex;
  min-height: 36px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.auth-wallet-body .moddio-wallet-view-heading h3 {
  margin: 0;
  color: #dce2e8;
  font-size: 17px;
  font-weight: 650;
  line-height: 1.2;
}

.auth-wallet-body .moddio-wallet-period-controls,
.auth-wallet-body .moddio-wallet-transaction-controls {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 6px;
}

.auth-wallet-body .moddio-wallet-period-controls label,
.auth-wallet-body .moddio-wallet-transaction-controls label {
  color: #89949f;
  font-size: 11px;
  font-weight: 600;
}

.auth-wallet-body .moddio-wallet-period-controls select,
.auth-wallet-body .moddio-wallet-transaction-controls select,
.auth-wallet-body .moddio-wallet-transaction-controls input {
  height: 32px;
  min-width: 0;
  padding: 4px 7px;
  border: 1px solid #384149;
  border-radius: 4px;
  background: #111418;
  color: #dce2e8;
  font-size: 12px;
}

.auth-wallet-body .moddio-wallet-transaction-controls select {
  width: 165px;
}

.auth-wallet-body .moddio-wallet-table-wrap {
  max-width: 100%;
  overflow: auto;
  border: 1px solid #30373e;
  border-radius: 5px;
}

.auth-wallet-body .moddio-wallet-table {
  width: 100%;
  min-width: 780px;
  border-collapse: collapse;
  color: #cbd3db;
  font-size: 12px;
}

.auth-wallet-body .moddio-wallet-summary-table {
  min-width: 930px;
  table-layout: fixed;
}

.auth-wallet-body .moddio-wallet-table th,
.auth-wallet-body .moddio-wallet-table td {
  min-width: 88px;
  padding: 8px 9px;
  border-right: 1px solid #30373e;
  border-bottom: 1px solid #30373e;
  text-align: left;
  vertical-align: middle;
  white-space: nowrap;
}

.auth-wallet-body .moddio-wallet-summary-table th,
.auth-wallet-body .moddio-wallet-summary-table td {
  text-align: center;
  white-space: normal;
}

.auth-wallet-body .moddio-wallet-table th {
  background: #20262c;
  color: #aeb8c2;
  font-size: 11px;
  font-weight: 700;
}

.auth-wallet-body .moddio-wallet-table thead tr:first-child th {
  background: #252c32;
  color: #dbe2e8;
}

.auth-wallet-body .moddio-wallet-table tbody tr:nth-child(even) td {
  background: #191e23;
}

.auth-wallet-body .moddio-wallet-table tbody tr:hover td {
  background: #222a30;
}

.auth-wallet-body .moddio-wallet-table th:last-child,
.auth-wallet-body .moddio-wallet-table td:last-child {
  border-right: 0;
}

.auth-wallet-body .moddio-wallet-table tbody tr:last-child td {
  border-bottom: 0;
}

.auth-wallet-body #modd-wallet-report-status {
  min-height: 18px;
  margin: 8px 0 0;
  font-size: 11px;
}

@media (max-width: 640px) {
  .auth-wallet-tabs {
    padding: 10px 8px 0;
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  .auth-wallet-tab {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .auth-wallet-body {
    padding: 14px 12px;
  }

  .auth-wallet-body .moddio-wallet-view-heading,
  .auth-wallet-body .moddio-wallet-transaction-controls {
    align-items: stretch;
    flex-direction: column;
  }

  .auth-wallet-body .moddio-wallet-period-controls {
    align-self: stretch;
  }

  .auth-wallet-body .moddio-wallet-period-controls select,
  .auth-wallet-body .moddio-wallet-transaction-controls select,
  .auth-wallet-body .moddio-wallet-transaction-controls input {
    width: 100%;
  }
}

.auth-wallet-body [data-account-wallet-view][hidden] {
  display: none !important;
}

.moddio-skin-shop-body {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 10px;
}

.moddio-skin-shop-sidebar,
.moddio-skin-shop-content {
  min-width: 0;
}

.moddio-skin-search {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px;
  border: 2px solid var(--modal-coin-background-color);
  border-radius: 10px;
  background: var(--modal-tab-active-bg-color);
  color: var(--modal-text-color);
}

.moddio-skin-search input {
  min-width: 0;
  width: 100%;
  height: 28px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--modal-text-color);
}

.moddio-skin-search input::placeholder {
  color: var(--modal-text-color);
}

.moddio-add-skin-button {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 4px;
  padding: 8px;
  border: 0;
  border-radius: 5px;
  background: #046c4e;
  color: #ffffff;
  cursor: pointer;
  text-decoration: none;
}

#coinshop {
  padding: 8px;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
  text-align: center;
}

.braains-discord-description {
  margin-bottom: 8px;
  color: #212529;
  font-size: 14px;
  line-height: 1.35;
}

#braains-discord-card {
  display: block;
  overflow: hidden;
  text-decoration: none;
}

#braains-discord-card img {
  display: block;
  width: 100%;
  height: auto;
}

.moddio-skin-submission-form {
  display: grid;
  gap: 10px;
}

.moddio-skin-submission-form label {
  margin: 0;
  color: #cdd4dc;
  font-size: 13px;
  font-weight: 600;
}

.moddio-skin-submission-form input,
.moddio-skin-submission-form select,
.moddio-skin-submission-form textarea {
  width: 100%;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid #3a424b;
  border-radius: 4px;
  background: #11161a;
  color: #d7dde4;
  font: inherit;
}

.moddio-skin-submission-form textarea {
  resize: vertical;
}

.moddio-skin-submission-preview {
  display: grid;
  min-height: 150px;
  place-items: center;
  border: 1px solid #30373e;
  background: #111418;
}

.moddio-skin-submission-preview[hidden] {
  display: none;
}

.moddio-skin-submission-preview img {
  width: 140px;
  height: 140px;
  object-fit: contain;
}

.moddio-skin-categories {
  margin-top: 8px;
}

#modd-shop-modal .shop-sidebar ul,
#modd-shop-modal .shop-sidebar li {
  margin: 0;
  padding: 0;
  list-style-type: none;
}

.moddio-skin-category {
  margin-top: 4px !important;
  border: 2px solid #6b7280;
  border-radius: 5px !important;
  cursor: pointer;
}

.moddio-skin-category.active {
  border-color: var(--modal-tab-active-bg-color);
  background: var(--modal-tab-active-bg-color);
}

.moddio-skin-action {
  width: 100%;
  min-height: 30px;
  padding: 3px 6px;
  border: 2px solid var(--modal-bg-color);
  border-radius: 4px;
  background: transparent;
  color: var(--modal-bg-color);
  cursor: pointer;
  font-weight: 700;
}

.moddio-skin-card.is-owned .moddio-skin-action {
  border-color: #254edb;
  background: #254edb;
  color: #ffffff;
}

.moddio-skin-card.is-equipped .moddio-skin-action {
  background: var(--modal-bg-color);
}

.moddio-skin-pagination {
  display: flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: 8px;
}

.moddio-skin-page {
  min-width: 34px;
  min-height: 34px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #ffffff;
  cursor: pointer;
  font-weight: 700;
}

.moddio-skin-page.is-active {
  border: 4px solid var(--modal-bg-color);
}

.moddio-purchase-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.moddio-purchase-image {
  width: 100px;
  height: 100px;
  padding: 4px;
  border-radius: 6px;
  background: #908c8c;
  object-fit: contain;
}

.moddio-purchase-price {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 18px;
}

.moddio-button {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 6px 12px;
  border: 1px solid transparent;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  line-height: 1.4;
}

.moddio-button:disabled {
  cursor: default;
  opacity: 0.65;
}

.moddio-button.btn-success {
  border-color: #198754;
  background: #198754;
  color: #ffffff;
}

.moddio-button.btn-outline-success {
  border-color: #198754;
  background: #ffffff;
  color: #198754;
}

.moddio-button.btn-outline-secondary {
  border-color: #6c757d;
  background: #ffffff;
  color: #6c757d;
}

.moddio-button.btn-secondary {
  border-color: #6c757d;
  background: #6c757d;
  color: #ffffff;
}

.moddio-button.btn-danger {
  border-color: #dc3545;
  background: #dc3545;
  color: #ffffff;
}

.moddio-button.btn-light {
  border-color: #dee2e6;
  background: #f8f9fa;
  color: #212529;
}

.moddio-button:not(:disabled):hover,
.moddio-button:not(:disabled):focus-visible {
  filter: brightness(0.94);
  outline: 2px solid #86b7fe;
  outline-offset: 1px;
}

.moddio-setting-row {
  display: grid;
  grid-template-columns: minmax(105px, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #e9ecef;
}

.moddio-setting-row:last-child {
  border-bottom: 0;
}

.moddio-setting-row label,
.moddio-setting-row > span {
  margin: 0;
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
}

.moddio-setting-control {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.moddio-setting-control .moddio-button.btn-light {
  border-color: #636363;
  background: #636363;
  color: #ffffff;
}

.moddio-setting-control input[type="range"] {
  width: min(190px, 42vw);
  accent-color: #198754;
}

.moddio-resolution-buttons {
  width: min(100%, 300px);
  flex-wrap: nowrap;
}

.moddio-resolution-buttons .moddio-button {
  min-width: 0;
  flex: 1 1 0;
  padding-right: 7px;
  padding-left: 7px;
  white-space: nowrap;
}

.moddio-volume-value {
  width: 40px;
  color: #ffffff;
  font-size: 12px;
  text-align: right;
}

.moddio-highscore-table {
  width: 100%;
  border-collapse: collapse;
  color: var(--modal-text-color);
  font-size: 14px;
}

.moddio-highscore-table th,
.moddio-highscore-table td {
  padding: 8px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
  text-align: left;
}

.moddio-highscore-table th:last-child,
.moddio-highscore-table td:last-child {
  text-align: right;
}

.moddio-highscore-table tbody tr.is-current-user {
  background: #212529;
  color: #99ff00;
  font-weight: 800;
}

.moddio-empty-state,
.moddio-status {
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.75);
  font-size: 13px;
  line-height: 1.45;
}

.moddio-status:empty {
  display: none;
}

.moddio-status.is-error {
  color: #dc3545;
}

.moddio-status.is-success {
  color: #198754;
}

.moddio-feedback-form {
  display: grid;
  gap: 8px;
}

.moddio-feedback-form label {
  margin: 0;
  color: #212529;
  font-size: 14px;
  font-weight: 600;
}

.moddio-feedback-form select,
.moddio-feedback-form textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  background: #ffffff;
  color: #212529;
  font: inherit;
}

.moddio-feedback-form textarea {
  min-height: 130px;
  resize: vertical;
}

.moddio-feedback-form select:focus,
.moddio-feedback-form textarea:focus {
  border-color: #86b7fe;
  outline: 0;
  box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.18);
}

.moddio-feedback-panel {
  width: min(100%, 384px);
  border: 1px solid rgb(105, 113, 119);
  border-radius: 16px;
  padding: 16px;
  background: rgb(38, 41, 43);
  color: #ffffff;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.moddio-feedback-panel .moddio-modal-header {
  position: relative;
  min-height: 38px;
  padding: 0 0 8px;
  border: 0;
}

.moddio-feedback-panel .moddio-modal-header h2 {
  margin-left: 8px;
  color: rgb(236, 237, 238);
  font-size: 20px;
  font-weight: 600;
  line-height: 24px;
}

.moddio-feedback-panel .moddio-close-button {
  position: absolute;
  top: -8px;
  right: -8px;
  color: rgb(105, 113, 119);
}

.moddio-feedback-panel .moddio-close-button:hover,
.moddio-feedback-panel .moddio-close-button:focus-visible {
  color: rgb(120, 127, 133);
}

.moddio-feedback-panel .moddio-modal-body {
  padding: 0;
  background: transparent;
}

.moddio-feedback-categories {
  display: grid;
  gap: 4px;
}

.moddio-feedback-category {
  width: 100%;
  min-height: 42px;
  padding: 12px 16px;
  border: 1px solid rgb(76, 81, 85);
  border-radius: 6px;
  background: transparent;
  color: #ffffff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  text-align: left;
}

.moddio-feedback-category:hover,
.moddio-feedback-category:focus-visible {
  border-color: rgb(0, 114, 245);
  outline: none;
}

.moddio-feedback-fields {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.moddio-feedback-fields[hidden],
.moddio-feedback-success[hidden],
.moddio-feedback-form[hidden],
.moddio-feedback-category[hidden] {
  display: none;
}

.moddio-feedback-form textarea,
.moddio-feedback-form input {
  width: 100%;
  border: 0;
  border-radius: 8px;
  background: rgb(43, 47, 49);
  color: rgb(236, 237, 238);
  font: inherit;
}

.moddio-feedback-form textarea {
  height: 128px;
  min-height: 128px;
  padding: 8px;
}

.moddio-feedback-form input {
  min-height: 38px;
  padding: 8px 12px;
}

.moddio-feedback-email-label {
  margin-bottom: -8px;
  color: #d9e3dd;
  font-size: 13px;
  font-weight: 600;
}

.moddio-feedback-form textarea:focus,
.moddio-feedback-form input:focus {
  outline: 2px solid rgb(0, 114, 245);
  outline-offset: 1px;
}

.moddio-feedback-submit {
  min-height: 38px;
  width: 100%;
  border: 1px solid rgb(0, 114, 245);
  border-radius: 6px;
  background: rgb(9, 82, 165);
  color: #ffffff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
}

.moddio-feedback-submit:disabled {
  cursor: default;
  opacity: 0.6;
}

.moddio-feedback-submit:not(:disabled):hover,
.moddio-feedback-submit:not(:disabled):focus-visible {
  outline: 2px solid rgb(0, 114, 245);
  outline-offset: 1px;
}

.moddio-feedback-success {
  display: flex;
  min-height: 200px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #ffffff;
  text-align: center;
}

.moddio-feedback-success strong {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
}

.moddio-feedback-success span {
  margin: 0;
  font-size: 14px;
}

.moddio-feedback-thread {
  display: grid;
  gap: 12px;
  padding: 4px 0;
}

.moddio-feedback-thread[hidden] {
  display: none;
}

.moddio-feedback-thread-messages {
  display: grid;
  gap: 10px;
  max-height: min(440px, calc(100vh - 280px));
  overflow: auto;
}

.moddio-feedback-thread-entry {
  padding: 10px 12px;
  border-left: 3px solid #72e5b0;
  background: rgba(19, 104, 70, 0.16);
  color: #f0f3ed;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.moddio-feedback-thread-entry.is-reply {
  border-left-color: #f5c95d;
}

.moddio-feedback-thread-entry time {
  display: block;
  margin-bottom: 5px;
  color: #aebbb4;
  font-size: 12px;
}

/* Feedback follows the account settings charcoal palette. */
#feedback-modal.moddio-modal-backdrop:not([hidden]) { background: rgba(4, 7, 10, .66); }
#feedback-modal .moddio-feedback-panel {
  position: relative;
  isolation: isolate;
  width: min(100%, 460px);
  border: 1px solid #384149;
  border-radius: 7px;
  padding: 19px 20px 20px;
  background: #15191d;
  color: #cdd4dc;
  box-shadow: 0 20px 56px rgba(0,0,0,.58);
  animation: feedback-panel-in 130ms ease-out both;
}
#feedback-modal .moddio-feedback-panel::before { content: none; }
#feedback-modal .moddio-feedback-panel .moddio-modal-header {
  min-height: 46px; align-items: flex-start; padding: 1px 38px 12px 0;
  border-bottom: 1px solid #30373e;
}
#feedback-modal .moddio-feedback-heading h2 {
  margin: 0; color: #eef1f4; font-size: 22px; font-weight: 700; line-height: 1.2;
}
#feedback-modal .moddio-feedback-heading p { margin: 6px 0 0; color: #aeb7c0; font-size: 13px; line-height: 1.4; }
#feedback-modal .moddio-close-button {
  top: 0; right: 0; display: grid; width: 34px; height: 34px; place-items: center;
  border: 1px solid #384149; border-radius: 5px; background: #20262c;
  color: #cdd4dc; font-size: 23px; line-height: 1;
  transition: background-color 130ms ease,border-color 130ms ease;
}
#feedback-modal .moddio-close-button:hover,
#feedback-modal .moddio-close-button:focus-visible {
  border-color: #7b8792; background: #303840; color: #fff; outline: 2px solid rgba(160,170,180,.3);
  outline-offset: 2px;
}
#feedback-modal .moddio-modal-body { padding-top: 15px; }
#feedback-modal .moddio-feedback-categories { gap: 8px; }
#feedback-modal .moddio-feedback-category {
  position: relative; min-height: 48px; padding: 12px 14px 12px 42px;
  border: 1px solid #384149; border-radius: 5px;
  background: #20262c; color: #cdd4dc;
  box-shadow: inset 0 1px rgba(255,255,255,.035);
  transition: border-color 140ms ease,box-shadow 140ms ease,background-color 140ms ease;
}
#feedback-modal .moddio-feedback-category::before {
  position: absolute; left: 14px; top: 50%; display: grid; width: 18px; height: 18px; place-items: center;
  border: 1px solid #59636e; border-radius: 5px; color: #c2c9d0;
  font-size: 12px; font-weight: 800; line-height: 1; transform: translateY(-50%);
}
#feedback-modal .moddio-feedback-category[data-feedback-category="bug"]::before { content: '!'; }
#feedback-modal .moddio-feedback-category[data-feedback-category="suggestion"]::before { content: '✦'; }
#feedback-modal .moddio-feedback-category[data-feedback-category="other"]::before { content: '…'; }
#feedback-modal .moddio-feedback-category:hover,
#feedback-modal .moddio-feedback-category:focus-visible {
  border-color: #7b8792; background: #282f36;
  box-shadow: inset 0 0 0 1px rgba(180,190,200,.1);
  outline: 2px solid rgba(160,170,180,.22); outline-offset: 2px;
}
#feedback-modal .moddio-feedback-category.is-selected {
  border: 2px solid #89949f; padding-left: 41px; background: #303840;
  color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.07);
}
#feedback-modal .moddio-feedback-fields { gap: 9px; margin-top: 14px; animation: feedback-fields-in 170ms ease-out both; }
#feedback-modal .moddio-feedback-email-label { margin: 3px 0 -4px; color: #e3eee5; font-size: 13px; font-weight: 700; }
#feedback-modal .moddio-feedback-form textarea,
#feedback-modal .moddio-feedback-form input {
  border: 1px solid #384149; border-radius: 5px; background: #11161a; color: #e3e7eb;
  box-shadow: inset 0 1px 3px rgba(0,0,0,.24);
  transition: border-color 130ms ease,box-shadow 130ms ease,background-color 130ms ease;
}
#feedback-modal .moddio-feedback-form textarea { min-height: 140px; padding: 11px 12px; line-height: 1.45; }
#feedback-modal .moddio-feedback-form input { min-height: 44px; padding: 9px 12px; }
#feedback-modal .moddio-feedback-form textarea::placeholder,
#feedback-modal .moddio-feedback-form input::placeholder { color: #89939d; opacity: 1; }
#feedback-modal .moddio-feedback-form textarea:focus,
#feedback-modal .moddio-feedback-form input:focus {
  border-color: #7b8792; background: #171d22;
  box-shadow: inset 0 1px 3px rgba(0,0,0,.24),0 0 0 3px rgba(150,160,170,.16); outline: none;
}
#feedback-modal .moddio-feedback-submit {
  min-height: 44px; margin-top: 3px; border: 1px solid #59636e; border-radius: 5px;
  background: #303840; color: #eef1f4; font-size: 15px;
  font-weight: 700; box-shadow: inset 0 1px rgba(255,255,255,.07);
  transition: background-color 130ms ease,border-color 130ms ease;
}
#feedback-modal .moddio-feedback-submit:not(:disabled):hover,
#feedback-modal .moddio-feedback-submit:not(:disabled):focus-visible {
  border-color: #89949f; background: #3a444e; outline: 2px solid rgba(160,170,180,.25);
  outline-offset: 2px;
}
#feedback-modal .moddio-feedback-success {
  min-height: 190px; margin-top: 12px; padding: 22px; border: 1px solid #384149; border-radius: 6px;
  background: #1b2025; animation: feedback-fields-in 180ms ease-out both;
}
#feedback-modal .moddio-feedback-success strong { color: #eef1f4; font-size: 20px; }
#feedback-modal .moddio-feedback-success span { color: #aeb7c0; line-height: 1.5; }
#feedback-modal .moddio-feedback-thread-entry {
  border: 1px solid #384149; border-left: 3px solid #59636e; border-radius: 5px;
  animation: feedback-fields-in 170ms ease-out both;
}
#feedback-modal .moddio-feedback-thread-entry.is-reply {
  border-color: #424b54; border-left: 3px solid #89949f; background: #1b2025;
}
@keyframes feedback-panel-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes feedback-fields-in { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) {
  #feedback-modal.moddio-modal-backdrop:not([hidden]),#feedback-modal .moddio-feedback-panel,
  #feedback-modal .moddio-feedback-fields,#feedback-modal .moddio-feedback-success,
  #feedback-modal .moddio-feedback-thread-entry { animation: none; }
  #feedback-modal .moddio-feedback-category,#feedback-modal .moddio-close-button,
  #feedback-modal .moddio-feedback-submit,#feedback-modal .moddio-feedback-form textarea,
  #feedback-modal .moddio-feedback-form input { transition: none; }
}

body.moddio-dialog-open {
  overflow: hidden !important;
}

@media (max-width: 560px) {
  html.phone-client #moddio-menu-actions {
    right: 10px;
    flex-wrap: wrap;
  }

  html.phone-client #moddio-menu-tabs {
    max-width: calc(100vw - 58px);
    flex-wrap: wrap;
  }

  html.phone-client .moddio-modal-backdrop {
    align-items: end;
    padding: 0;
  }

  html.phone-client .moddio-modal,
  html.phone-client .moddio-modal-sm {
    width: 100%;
    max-height: 94vh;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 6px 6px 0 0;
  }

  html.phone-client .moddio-skin-shop-modal {
    max-height: 94vh;
  }

  html.phone-client .moddio-feedback-panel {
    width: min(calc(100vw - 24px), 460px);
    margin-bottom: 10px;
    border-radius: 12px;
  }

  html.phone-client .moddio-modal-body {
    max-height: calc(94vh - 124px);
  }

  html.phone-client .staff-moderation-table,
  html.phone-client .staff-moderation-table tbody,
  html.phone-client .staff-moderation-table tr,
  html.phone-client .staff-moderation-table td {
    display: block;
    width: 100%;
  }

  html.phone-client .staff-moderation-table thead {
    display: none;
  }

  html.phone-client .staff-moderation-table td:last-child {
    padding-top: 0;
    text-align: left;
  }

  html.phone-client .staff-moderation-actions {
    justify-content: flex-start;
  }

  html.phone-client .moddio-skin-shop-body {
    grid-template-columns: 1fr;
  }

  html.phone-client .moddio-skin-categories {
    display: flex;
    overflow-x: auto;
    gap: 4px;
  }

  html.phone-client .moddio-skin-category {
    width: auto;
    flex: 0 0 auto;
    white-space: nowrap;
  }

  html.phone-client .moddio-skin-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    min-height: 0;
  }

  html.phone-client .moddio-setting-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  html.phone-client .moddio-setting-control {
    justify-content: flex-start;
  }
}

/* Account Settings palette. */
#settings-modal {
  background: rgba(4, 7, 10, 0.78);
  backdrop-filter: blur(8px);
}

#modd-shop-modal,
#skin-submission-modal,
#purchasable-purchase-modal,
#validate-user-pin-modal {
  background: rgba(4, 7, 10, 0.78);
  backdrop-filter: blur(8px);
}

#settings-modal .moddio-modal,
#modd-shop-modal .moddio-modal,
#skin-submission-modal .moddio-modal,
#purchasable-purchase-modal .moddio-modal,
#validate-user-pin-modal .moddio-modal {
  border: 1px solid #30363d;
  border-radius: 7px;
  background: #15191d;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.62);
  color: #cdd4dc;
}

#settings-modal .moddio-modal-header,
#skin-submission-modal .moddio-modal-header,
#purchasable-purchase-modal .moddio-modal-header,
#validate-user-pin-modal .moddio-modal-header {
  min-height: 56px;
  padding: 12px 18px;
  border-bottom: 1px solid #2b3138;
  background: #171b20;
}

#modd-shop-modal .moddio-modal-header {
  min-height: 56px;
  padding: 12px 18px;
  border-bottom: 1px solid #2b3138;
  background: #171b20;
}

#settings-modal .moddio-modal-header h2,
#modd-shop-modal .moddio-modal-header h2,
#skin-submission-modal .moddio-modal-header h2,
#purchasable-purchase-modal .moddio-modal-header h2,
#validate-user-pin-modal .moddio-modal-header h2 {
  color: #d7dde4;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.3;
}

#settings-modal .moddio-close-button,
#modd-shop-modal .moddio-close-button,
#skin-submission-modal .moddio-close-button,
#purchasable-purchase-modal .moddio-close-button,
#validate-user-pin-modal .moddio-close-button {
  color: #747f8b;
}

#settings-modal .moddio-close-button:hover,
#settings-modal .moddio-close-button:focus-visible,
#modd-shop-modal .moddio-close-button:hover,
#modd-shop-modal .moddio-close-button:focus-visible,
#skin-submission-modal .moddio-close-button:hover,
#skin-submission-modal .moddio-close-button:focus-visible,
#purchasable-purchase-modal .moddio-close-button:hover,
#purchasable-purchase-modal .moddio-close-button:focus-visible,
#validate-user-pin-modal .moddio-close-button:hover,
#validate-user-pin-modal .moddio-close-button:focus-visible {
  color: #cdd4dc;
  outline-color: #59636e;
}

#settings-modal .moddio-modal-body {
  padding: 12px 18px;
  background: #15191d;
}

#settings-modal .moddio-modal-footer {
  border-top: 1px solid #30373e;
  background: #151a1f;
}

#settings-modal .moddio-setting-row {
  border-bottom-color: #30373e;
}

#settings-modal .moddio-setting-row label,
#settings-modal .moddio-setting-row > span,
#settings-modal .moddio-volume-value {
  color: #aeb7c0;
}

#settings-modal .moddio-setting-control .moddio-button.btn-success,
#settings-modal .moddio-modal-footer .btn-primary {
  border-color: #408b65;
  background: #347456;
  color: #e1eee7;
}

#settings-modal .moddio-setting-control .moddio-button.btn-light,
#settings-modal .moddio-setting-control .moddio-button.btn-secondary {
  border-color: #384149;
  background: #20262c;
  color: #aeb7c0;
}

#settings-modal .moddio-setting-control input[type="range"] {
  accent-color: #60b98a;
}

.moddio-setting-select {
  width: min(240px, 100%);
  min-height: 38px;
  padding: 7px 34px 7px 10px;
  border: 1px solid #384149;
  border-radius: 5px;
  background: #11161a;
  color: #cbd3db;
  font: inherit;
}

.moddio-setting-select:focus-visible {
  border-color: #60b98a;
  outline: 2px solid rgba(96, 185, 138, 0.25);
  outline-offset: 1px;
}

.moddio-setting-help {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 8px 0 4px;
  color: #8d98a4;
  font-size: 12px;
  line-height: 1.5;
}

.moddio-setting-help[hidden] {
  display: none;
}

.moddio-setting-help strong {
  color: #c8d0d8;
}

.moddio-renderer-pipeline-row .moddio-setting-value {
  color: #72c99a;
  font-size: 12px;
  font-weight: 700;
  text-align: right;
}

#settings-modal #renderer-webgpu.btn-success {
  border-color: #4b9d73;
  background: #347456;
}

#settings-modal [data-setting="renderer-mode"]:hover:not(:focus-visible) {
  outline: none;
}

#settings-modal [data-setting="renderer-mode"]:focus-visible {
  outline: 2px solid #60b98a;
  outline-offset: 2px;
}

@media (max-width: 575px) {
  .moddio-renderer-pipeline-row .moddio-setting-value { text-align: left; }
  #settings-modal .moddio-setting-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }
  #settings-modal .moddio-setting-control { justify-content: flex-start; }
  #settings-modal #renderer-setting-row {
    grid-template-columns: minmax(0, 1fr);
  }
  #settings-modal #renderer-setting-row [role="group"][aria-label="Renderer"] {
    display: grid;
    width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
  }
  #settings-modal #renderer-setting-row [role="group"][aria-label="Renderer"] .moddio-button {
    min-width: 0;
    padding-right: 5px;
    padding-left: 5px;
    white-space: nowrap;
  }
}

.moddio-setting-help a {
  color: #70c899;
}

#modd-shop-modal .moddio-balance {
  border: 1px solid #384149;
  border-radius: 5px;
  background: #20262c;
  color: #cdd4dc;
}

#modd-shop-modal .moddio-skin-shop-body {
  gap: 0;
  padding: 0;
  background: #15191d;
}

#modd-shop-modal .moddio-skin-shop-sidebar {
  padding: 16px 14px;
  border-right: 1px solid #30373e;
  background: #151a1f;
}

#modd-shop-modal .moddio-skin-shop-content {
  padding: 16px;
  background: #15191d;
}

#modd-shop-modal .moddio-skin-search {
  padding: 7px 9px;
  border: 1px solid #384149;
  border-radius: 5px;
  background: #11161a;
  color: #8d98a4;
}

#modd-shop-modal .moddio-skin-search:focus-within {
  border-color: #60b98a;
  box-shadow: 0 0 0 2px rgba(96, 185, 138, 0.25);
}

#modd-shop-modal .moddio-skin-search input {
  color: #cdd4dc;
}

#modd-shop-modal .moddio-skin-search input::placeholder {
  color: #747f8b;
}

#modd-shop-modal .moddio-add-skin-button {
  border: 1px solid #408b65;
  border-radius: 5px;
  background: #347456;
  color: #e1eee7;
}

#modd-shop-modal .moddio-add-skin-button:hover,
#modd-shop-modal .moddio-add-skin-button:focus-visible {
  border-color: #60b98a;
  background: #408b65;
  color: #ffffff;
  outline: 2px solid rgba(96, 185, 138, 0.25);
  outline-offset: 1px;
}

#modd-shop-modal .moddio-skin-category {
  border: 1px solid #384149;
  border-radius: 5px !important;
  background: #20262c;
  color: #aeb7c0;
}

#modd-shop-modal .moddio-skin-category:hover,
#modd-shop-modal .moddio-skin-category:focus-visible {
  border-color: #60b98a;
  background: #293139;
  color: #d7dde4;
  outline: 2px solid rgba(96, 185, 138, 0.25);
  outline-offset: 1px;
}

#modd-shop-modal .moddio-skin-category.active {
  border-color: #408b65;
  background: #347456;
  color: #e1eee7;
}

#modd-shop-modal .moddio-skin-grid {
  gap: 10px;
}

#modd-shop-modal .moddio-skin-card {
  min-height: 154px;
  padding: 8px;
  border: 1px solid #30373e;
  border-radius: 6px;
  background: #151a1f;
  color: #cdd4dc;
  box-shadow: none;
}

#modd-shop-modal .moddio-skin-card:hover {
  border-color: #384149;
  background: #20262c;
}

#modd-shop-modal .moddio-skin-card.is-owned {
  border-color: #408b65;
  background: #19231f;
}

#modd-shop-modal .moddio-skin-card.is-equipped {
  border-color: #60b98a;
  box-shadow: inset 0 0 0 1px #60b98a;
}

#modd-shop-modal .moddio-skin-image {
  margin-bottom: 10px;
}

#modd-shop-modal .moddio-skin-details {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #e0e5ea;
  line-height: 1.2;
  text-align: center;
}

#modd-shop-modal .moddio-skin-name,
#modd-shop-modal .moddio-skin-creator {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#modd-shop-modal .moddio-skin-name {
  font-size: 12px;
  font-weight: 600;
}

#modd-shop-modal .moddio-skin-creator {
  margin-top: 2px;
  color: #9aa4ae;
  font-size: 11px;
}

#modd-shop-modal .moddio-skin-action {
  min-height: 32px;
  padding: 5px 8px;
  border: 1px solid #384149;
  border-radius: 4px;
  background: #20262c;
  color: #aeb7c0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025);
}

#modd-shop-modal .moddio-skin-action:hover,
#modd-shop-modal .moddio-skin-action:focus-visible {
  border-color: #60b98a;
  background: #293139;
  color: #d7dde4;
  outline: 2px solid rgba(96, 185, 138, 0.25);
  outline-offset: 1px;
}

#modd-shop-modal .moddio-skin-card.is-owned .moddio-skin-action,
#modd-shop-modal .moddio-skin-card.is-equipped .moddio-skin-action {
  border-color: #408b65;
  background: #347456;
  color: #e1eee7;
}

#modd-shop-modal .moddio-skin-card.is-equipped .moddio-skin-action {
  border-color: #60b98a;
  background: #408b65;
}

#modd-shop-modal .moddio-skin-page {
  color: #8e99a5;
}

#modd-shop-modal .moddio-skin-page:hover,
#modd-shop-modal .moddio-skin-page:focus-visible {
  background: #20262c;
  color: #d7dde4;
  outline: 2px solid rgba(96, 185, 138, 0.25);
  outline-offset: 1px;
}

#modd-shop-modal .moddio-skin-page.is-active {
  border: 1px solid #408b65;
  background: #347456;
  color: #e1eee7;
}

#purchasable-purchase-modal .moddio-modal-body {
  background: #15191d;
}

/* Braains Io original PIN validation flow: a separate, large confirmation surface. */
#validate-user-pin-modal {
  z-index: 1200;
}

#validate-user-pin-modal .moddio-pin-validation-modal {
  width: min(760px, calc(100vw - 28px));
  min-height: min(650px, calc(100vh - 28px));
}

#validate-user-pin-modal .moddio-pin-validation-body {
  display: flex;
  min-height: min(590px, calc(100vh - 100px));
  align-items: center;
  justify-content: center;
  padding: clamp(24px, 6vw, 72px);
  background: #15191d;
}

.moddio-pin-screen {
  width: min(100%, 560px);
  margin: 0 auto;
  text-align: center;
}

.moddio-pin-screen h1 {
  margin: 0 0 10px;
  color: #f0f3f6;
  font-size: clamp(26px, 4vw, 36px);
  font-weight: 700;
}

.moddio-pin-screen > p:not(.moddio-pin-field-label):not(.moddio-pin-status) {
  margin: 0 auto 30px;
  color: #aeb7c0;
  font-size: clamp(15px, 2vw, 19px);
  line-height: 1.55;
}

.moddio-pin-field-label {
  margin: 22px 0 10px;
  color: #d7dde4;
  font-size: 17px;
  text-align: left;
}

.moddio-pin-inputs {
  display: flex;
  justify-content: center;
  gap: clamp(8px, 2vw, 14px);
}

.moddio-pin-inputs input {
  width: clamp(54px, 12vw, 72px);
  height: clamp(58px, 12vw, 76px);
  border: 1px solid #59636e;
  border-radius: 8px;
  background: #20262c;
  color: #f0f3f6;
  font: 700 clamp(26px, 5vw, 40px)/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-align: center;
}

.moddio-pin-inputs input:focus-visible {
  border-color: #60b98a;
  outline: 3px solid rgba(96, 185, 138, 0.25);
  outline-offset: 2px;
}

.moddio-pin-status {
  min-height: 24px;
  margin: 22px 0 16px;
  color: #e59b9b;
  font-size: 14px;
  line-height: 1.45;
}

.moddio-pin-status.is-success {
  color: #8fd8ae;
}

.moddio-pin-screen .moddio-button {
  min-width: 160px;
  min-height: 44px;
}

.moddio-pin-reset-link {
  display: block;
  margin-top: 22px;
  color: #aeb7c0;
  font-size: 14px;
  text-decoration: underline;
}

.moddio-pin-reset-link:hover,
.moddio-pin-reset-link:focus-visible {
  color: #f0f3f6;
}

#skin-submission-modal .moddio-modal-body {
  padding: 16px 18px;
  background: #15191d;
}

#purchasable-purchase-modal .moddio-purchase-image {
  border: 1px solid #353c44;
  background: #20262c;
}

#purchasable-purchase-modal .moddio-purchase-price {
  min-width: 112px;
  justify-content: center;
  padding: 7px 12px;
  border: 1px solid #4b5560;
  border-radius: 4px;
  background: #111418;
  color: #cdd4dc;
}

/* The PIN step is an in-shop purchase view, so the selected skin and security
   prompt share one dialog instead of opening a second page over the shop. */
#purchasable-purchase-modal.is-pin-validation .moddio-modal {
  width: min(760px, calc(100vw - 28px));
  min-height: min(650px, calc(100vh - 28px));
}

#purchasable-purchase-modal.is-pin-validation .moddio-modal-header h2 {
  font-size: 20px;
}

#validate-user-pin-modal {
  width: 100%;
  min-height: 0;
  background: transparent;
  backdrop-filter: none;
  z-index: auto;
}

#validate-user-pin-modal .moddio-pin-validation-body {
  width: 100%;
  min-height: min(590px, calc(100vh - 100px));
  border: 0;
}

#purchasable-purchase-modal:not(.is-pin-validation) #validate-user-pin-modal {
  display: none;
}

#purchasable-purchase-modal #confirm-purchase-btn {
  border-color: #59636e;
  background: #2b3239;
  color: #d7dde4;
}

#purchasable-purchase-modal #confirm-purchase-btn:hover,
#purchasable-purchase-modal #confirm-purchase-btn:focus-visible {
  background: #3a434c;
  outline: none;
}

@media (max-width: 560px) {
  html.phone-client #modd-shop-modal .moddio-modal,
  html.phone-client #purchasable-purchase-modal .moddio-modal,
  html.phone-client #validate-user-pin-modal .moddio-modal {
    border-radius: 7px 7px 0 0;
  }

  html.phone-client #modd-shop-modal .moddio-skin-shop-sidebar {
    border-right: 0;
    border-bottom: 1px solid #292f35;
  }
}

/* mobile-controls.css */
.source-mobile-controls {
  position: fixed;
  inset: 0;
  z-index: 11000;
  display: none;
  pointer-events: none;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

body.in-game .source-mobile-controls[data-enabled="true"] {
  display: block;
}

body.auth-dialog-open .source-mobile-controls,
body.auth-settings-open .source-mobile-controls,
body.moddio-dialog-open .source-mobile-controls {
  display: none !important;
}

#mobile-rotate-device {
  position: fixed;
  inset: 0;
  z-index: 120000;
  display: none;
  place-items: center;
  padding: 24px;
  background: rgba(8, 12, 18, 0.94);
  color: #fff;
  text-align: center;
  font-family: Arial, sans-serif;
  pointer-events: auto;
}

#mobile-rotate-device[data-visible="true"] {
  display: grid;
}

#mobile-rotate-device .mobile-rotate-card {
  display: grid;
  justify-items: center;
  gap: 18px;
  max-width: 280px;
}

#mobile-rotate-device .mobile-rotate-icon {
  width: 76px;
  height: 52px;
  border: 4px solid #fff;
  border-radius: 8px;
  position: relative;
  animation: mobile-device-rotate 1.8s ease-in-out infinite;
}

#mobile-rotate-device .mobile-rotate-icon::after {
  content: "";
  position: absolute;
  width: 5px;
  height: 5px;
  left: 50%;
  bottom: 5px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: #fff;
}

#mobile-rotate-device h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.1;
}

#mobile-rotate-device p {
  margin: 0;
  color: #cbd5e1;
  font-size: 15px;
  line-height: 1.4;
}

@keyframes mobile-device-rotate {
  0%, 20% { transform: rotate(0deg); }
  50%, 70% { transform: rotate(90deg); }
  100% { transform: rotate(90deg); }
}

@media (orientation: landscape) {
  #mobile-rotate-device[data-visible="true"] {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  #mobile-rotate-device .mobile-rotate-icon {
    animation: none;
  }
}

@media (max-width: 768px) {
  html.phone-client #modd-item-shop .modal-dialog-centered {
    transform: translateY(8vh);
  }
}

.source-mobile-stick,
.source-mobile-action {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: auto;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
}

.source-mobile-stick-zone {
  position: absolute;
  z-index: 0;
  aspect-ratio: 1;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: auto;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
}

.source-mobile-stick-zone[data-control="movementWheel"] {
  width: clamp(200px, 46vmin, 280px);
}

.source-mobile-stick-zone[data-control="lookWheel"] {
  width: clamp(164px, 38vmin, 230px);
}

.source-mobile-stick {
  z-index: 1;
  aspect-ratio: 1;
  border: 0;
  border-radius: 50%;
  background: rgba(10, 14, 19, 0.38);
  box-shadow: none;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 80ms ease;
}

.source-mobile-stick[data-control="movementWheel"] {
  width: clamp(120px, 28vmin, 164px);
}

.source-mobile-stick[data-control="lookWheel"] {
  width: clamp(92px, 21vmin, 126px);
}

.source-mobile-stick::after {
  content: "";
  position: absolute;
  inset: 28%;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.38);
  box-shadow: none;
  transform: translate(var(--thumb-x, 0px), var(--thumb-y, 0px));
}

.source-mobile-stick[data-active="true"] {
  background: rgba(15, 21, 28, 0.5);
}

.source-mobile-stick[data-visible="true"] {
  opacity: 1;
  visibility: visible;
}

.source-mobile-action {
  z-index: 2;
  display: grid;
  place-items: center;
  width: clamp(54px, 13vmin, 72px);
  aspect-ratio: 1;
  padding: 10px;
  border: 2px solid rgba(255, 255, 255, 0.72);
  border-radius: 50%;
  background: rgba(29, 35, 43, 0.58);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.32);
}

.source-mobile-action img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}

.source-mobile-action-label {
  color: #ffffff;
  font: 700 18px/1 Arial, sans-serif;
  pointer-events: none;
}

.source-mobile-action[data-active="true"] {
  transform: translate(-50%, -50%) scale(0.9);
  background: rgba(54, 66, 80, 0.82);
}

@media (pointer: fine) and (hover: hover) {
  .source-mobile-controls:not([data-force="true"]) {
    display: none !important;
  }
}

@media (max-width: 1024px) {
  html.phone-client .source-mobile-stick {
    transform: translate(-50%, -50%);
  }

  html.phone-client .source-mobile-action {
    transform: translate(-50%, calc(-50% + 12px));
  }

  html.phone-client .source-mobile-action[data-active="true"] {
    transform: translate(-50%, calc(-50% + 12px)) scale(0.9);
  }

  html.phone-client .source-mobile-action[data-control="b"] {
    left: 88% !important;
    top: 15% !important;
  }

  html.phone-client .source-mobile-action[data-control="g"] {
    left: 89% !important;
    top: 43% !important;
  }

  html.phone-client .source-mobile-action[data-control="e"] {
    left: 89% !important;
    top: 70% !important;
  }

  html.phone-client .source-mobile-action[data-control="button1"] {
    left: 75% !important;
    top: 70% !important;
  }

  html.phone-client .source-mobile-action[data-control="z"] {
    left: 84% !important;
    top: 72% !important;
  }

  html.phone-client .source-mobile-action[data-control="n"] {
    left: 60% !important;
    top: 15% !important;
  }

  html.phone-client body #moddio-menu-actions {
    top: calc(env(safe-area-inset-top, 0px) + 18px) !important;
    left: calc(env(safe-area-inset-left, 0px) + 8px) !important;
    gap: 3px;
  }

  html.phone-client #moddio-menu-button,
  html.phone-client #moddio-menu-tabs .nav-button {
    width: 28px;
    height: 28px;
    padding: 4px;
    border-radius: 5px;
    font-size: 12px;
  }

  html.phone-client #moddio-menu-tabs {
    max-width: calc(100vw - 50px);
    gap: 3px;
  }

  html.phone-client #moddio-menu-tabs .svg-style {
    width: 16px;
    height: 16px;
  }

  html.phone-client .moddio-modal-header {
    min-height: 44px;
    padding: 8px 12px;
  }

  html.phone-client .moddio-modal-header h2 {
    font-size: 20px;
    line-height: 1.2;
  }

  html.phone-client .moddio-close-button {
    width: 28px;
    height: 28px;
    font-size: 23px;
  }

  html.phone-client .staff-moderation-tabs {
    min-height: 36px;
    padding: 0 8px;
  }

  html.phone-client .staff-moderation-tab {
    min-height: 36px;
    gap: 4px;
    padding: 0 9px;
    font-size: 11px;
  }

  html.phone-client .auth-settings-tabs {
    padding: 5px;
  }

  html.phone-client .auth-settings-tabs button {
    min-height: 34px;
    gap: 6px;
    padding: 6px 9px;
    font-size: 12px;
  }

  html.phone-client .moddio-skin-categories {
    gap: 3px;
    margin-top: 5px;
  }

  html.phone-client #modd-shop-modal .moddio-skin-category,
  html.phone-client .moddio-skin-category {
    min-height: 30px;
    margin-top: 2px !important;
    padding: 5px 8px;
    font-size: 12px;
  }

  html.phone-client .moddio-skin-action,
  html.phone-client #modd-shop-modal .moddio-skin-action {
    min-height: 28px;
    padding: 4px 7px;
    font-size: 11px;
  }

  html.phone-client .chat-scope-tabs {
    min-height: 32px !important;
    gap: 3px !important;
  }

  html.phone-client .chat-scope-tab {
    min-height: 30px !important;
    padding: 4px 8px !important;
    font-size: 11px !important;
  }

  html.phone-client .moddio-feedback-category {
    min-height: 34px;
    padding: 8px 10px;
    font-size: 12px;
  }

  html.phone-client body #modd-item-shop .shop-panel {
    width: min(88vw, 620px) !important;
    max-height: 82dvh !important;
  }

  html.phone-client body #modd-item-shop .shop-header {
    padding: 9px 9px 7px 12px !important;
  }

  html.phone-client body #modd-item-shop .shop-title {
    font-size: 16px !important;
  }

  html.phone-client body #modd-item-shop .shop-description {
    margin-top: 2px !important;
    font-size: 11px !important;
  }

  html.phone-client body #modd-item-shop .shop-close {
    width: 28px !important;
    height: 28px !important;
  }

  html.phone-client body #modd-item-shop .shop-body {
    padding: 4px 12px 12px !important;
  }

  html.phone-client body #modd-item-shop .shop-grid {
    gap: 8px !important;
  }

  html.phone-client body #modd-item-shop .item-shop-button {
    min-height: 104px !important;
    gap: 6px !important;
    padding: 8px 6px !important;
  }

  html.phone-client body #modd-item-shop .item-icon-tile {
    padding: 5px !important;
  }

  html.phone-client body #modd-item-shop .item-icon-tile img,
  html.phone-client body #modd-item-shop .source-item-frame {
    width: 48px !important;
    height: 48px !important;
  }

  html.phone-client body #modd-item-shop .item-name {
    font-size: 12px !important;
  }
}

/* The captured desktop chat uses equal source tab cells. Keep the close and
   player-list controls stable while preventing label-specific padding from
   shifting Server, Community, and DMs out of alignment. */
@media (min-width: 769px) {
  #chat-box #tabs {
    display: grid !important;
    grid-template-columns: 32px repeat(3, minmax(0, 1fr)) 38px !important;
    width: 100%;
    align-items: stretch;
  }

  #chat-box #tabs > #toggle-player-list,
  #chat-box #tabs > .chat-scope-tab,
  #chat-box #tabs > #hide-chat-button {
    width: auto !important;
    min-width: 0 !important;
    flex: none !important;
    margin: 0 !important;
    padding: 4px 5px !important;
    box-sizing: border-box;
  }

  #chat-tab-container {
    width: min(30vw, 320px) !important;
  }
}
