.settings-mobile-v2 {
  display: none;
}
.settings-sheet {
  width: min(520px, calc(100vw - 24px));
  max-height: calc(100dvh - 24px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.settings-sheet form {
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.settings-sheet .modal-body {
  min-height: 0;
  overflow: auto;
}
.settings-sheet .mobile-field {
  display: grid;
  gap: 7px;
  margin-bottom: 15px;
  color: #596278;
  font-size: 12px;
}
.settings-sheet .mobile-field input {
  width: 100%;
  height: 48px;
  border: 1px solid #d5dce7;
  border-radius: 12px;
  padding: 0 13px;
  background: #fff;
  color: #101828;
  font: inherit;
  outline: 0;
}
.settings-sheet .mobile-field input:focus {
  border-color: #0caf78;
  box-shadow: 0 0 0 3px #0caf781c;
}
.settings-account-readonly {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin: 4px 0 15px;
}
.settings-account-readonly span {
  display: grid;
  gap: 4px;
  background: #f5f7fa;
  border-radius: 11px;
  padding: 11px;
  color: #697386;
  font-size: 11px;
}
.settings-account-readonly b {
  color: #16213f;
  overflow-wrap: anywhere;
  font-size: 12px;
}
.settings-password-button {
  width: 100%;
  height: 45px;
  border: 1px solid #d5dce7;
  border-radius: 11px;
  background: #fff;
  color: #1c2947;
  font: inherit;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.settings-backup-list {
  display: grid;
  gap: 9px;
}
.settings-backup-list > button {
  width: 100%;
  border: 1px solid #e0e5ec;
  background: #fff;
  border-radius: 13px;
  padding: 12px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 10px;
  text-align: left;
  color: #101828;
}
.settings-backup-list > button > svg:first-child {
  width: 38px;
  height: 38px;
  padding: 9px;
  border-radius: 11px;
  background: #eafaf4;
  color: #089b6b;
}
.settings-backup-list > button span {
  display: grid;
  gap: 3px;
}
.settings-backup-list > button small {
  color: #737c8f;
}
.settings-backup-list > button > svg:last-child {
  width: 16px;
  color: #98a2b3;
}
.settings-backup-list > button.danger > svg:first-child {
  background: #fff0f1;
  color: #d92d3e;
}
.settings-legacy-hooks {
  display: none !important;
}
@media (min-width:768px) {
  .settings-mobile-v2 {
    display: none !important;
  }
}
@media (max-width:767px) {
  .settings-mobile-v2 {
    display: block;
    margin: -4px -12px 0;
    padding: 2px 12px calc(104px + env(safe-area-inset-bottom));
    color: #0c1839;
  }
  .settings-page-heading {
    margin: 0 2px 18px;
  }
  .settings-page-heading h1 {
    font-size: 28px;
    line-height: 1.1;
    margin: 0 0 6px;
  }
  .settings-page-heading p {
    margin: 0;
    color: #697386;
    font-size: 14px;
  }
  .settings-sync-hero {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto 9px;
    gap: 12px;
    align-items: center;
    background: #fff;
    border: 1px solid #dce2eb;
    border-radius: 17px;
    padding: 13px 14px;
    box-shadow: 0 4px 14px #1822440b;
    margin-bottom: 18px;
  }
  .settings-sync-hero > span {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    color: #047857;
    background: #e8faf3;
  }
  .settings-sync-hero > span svg {
    width: 25px;
    height: 25px;
  }
  .settings-sync-hero h2 {
    font-size: 16px;
    color: #07875e;
    margin: 0 0 3px;
  }
  .settings-sync-hero p {
    margin: 0;
    color: #697386;
    font-size: 11px;
    line-height: 1.35;
  }
  .settings-sync-hero > small {
    display: grid;
    text-align: right;
    color: #697386;
    font-size: 9px;
    gap: 3px;
  }
  .settings-sync-hero > small b {
    color: #07875e;
    font-size: 11px;
  }
  .settings-sync-hero > i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #0caf78;
  }
  .settings-sync-hero.is-error > span {
    background: #fff0f1;
    color: #d92d3e;
  }
  .settings-sync-hero.is-error h2 {
    color: #c51f34;
  }
  .settings-sync-hero.is-error > i {
    background: #d92d3e;
  }
  .settings-group {
    margin: 0 0 14px;
    padding: 12px 11px 3px;
    background: #fff;
    border: 1px solid #e0e5ec;
    border-radius: 17px;
    box-shadow: 0 3px 12px #18224408;
  }
  .settings-group > h2 {
    font-size: 15px;
    margin: 0 0 9px 2px;
  }
  .settings-group > div {
    border: 1px solid #e2e7ee;
    border-radius: 13px;
    overflow: hidden;
  }
  .settings-list-row {
    width: 100%;
    min-width: 0;
    border: 0;
    border-bottom: 1px solid #e6eaf0;
    background: #fff;
    padding: 9px 10px;
    display: grid;
    grid-template-columns: 39px minmax(0, 1fr) auto 16px;
    gap: 9px;
    align-items: center;
    text-align: left;
    color: #0c1839;
  }
  .settings-list-row:last-child {
    border-bottom: 0;
  }
  .settings-row-icon {
    width: 39px;
    height: 39px;
    border-radius: 11px;
    background: #e9faf4;
    color: #07996a;
    display: grid;
    place-items: center;
  }
  .settings-row-icon svg {
    width: 20px;
  }
  .settings-list-row > span:nth-child(2) {
    display: grid;
    min-width: 0;
    gap: 2px;
  }
  .settings-list-row b {
    font-size: 13px;
  }
  .settings-list-row small {
    color: #697386;
    font-size: 10.5px;
    line-height: 1.25;
    white-space: normal;
  }
  .settings-list-row em {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-style: normal;
    color: #07996a;
    font-size: 10.5px;
    text-align: right;
  }
  .settings-list-row > svg {
    width: 15px;
    color: #6d7890;
  }
  .settings-mobile-v2 > .operation-mode-settings {
    margin: 0 0 14px !important;
    border: 1px solid #e0e5ec !important;
    border-radius: 17px !important;
    box-shadow: 0 3px 12px #18224408 !important;
  }
  .settings-logout {
    width: 100%;
    height: 47px;
    border: 1px solid #ffc7cd;
    border-radius: 13px;
    background: #fff7f8;
    color: #c51f34;
    font: inherit;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 8px;
  }
  .settings-version {
    text-align: center;
    color: #98a2b3;
    font-size: 10px;
    margin: 16px 0 0;
  }
  .settings-sheet {
    width: 100%;
    max-width: none;
    max-height: calc(100dvh - max(10px, env(safe-area-inset-top)));
    margin-top: auto;
    border-radius: 22px 22px 0 0;
  }
  .settings-sheet .modal-head {
    padding: 17px 16px 12px;
  }
  .settings-sheet .modal-body {
    padding: 15px 16px;
  }
  .settings-sheet .modal-foot {
    padding: 11px 16px max(13px, env(safe-area-inset-bottom));
  }
  .settings-sheet .modal-foot .mobile-button {
    flex: 1;
  }
  .settings-account-readonly {
    grid-template-columns: 1fr;
  }
  .settings-backup-sheet .modal-body {
    padding-bottom: 24px;
  }
}
@media (max-width: 359px) {
  .settings-mobile-v2 {
    margin-inline: -9px;
    padding-inline: 9px;
  }
  .settings-sync-hero {
    grid-template-columns: 44px minmax(0, 1fr) 8px;
    padding: 11px;
    gap: 9px;
  }
  .settings-sync-hero > span {
    width: 44px;
    height: 44px;
  }
  .settings-sync-hero > small {
    display: none;
  }
  .settings-list-row {
    grid-template-columns: 35px minmax(0, 1fr) 13px;
    padding: 8px;
  }
  .settings-row-icon {
    width: 35px;
    height: 35px;
  }
  .settings-list-row em {
    display: none;
  }
}
