/* The app's own pages outside the editor (sign-in, invitations, help, account settings, plans, invitations to friends,
   admin): the page's base, buttons, links, fields, notes and placeholders, in the brand's tokens (/brand.css), which this
   file uses and never restates. The workspace and Starling draw theirs with ui.css; the frame of the signed-in pages is
   shell.css. */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  background: var(--page-paper);
  color: var(--ink);
  font: 14px / var(--lh-ui) var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
[hidden] {
  display: none !important;
}
.theme-switching *,
.theme-switching *::before,
.theme-switching *::after {
  transition: none !important;
}
a {
  color: inherit;
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
button:disabled {
  cursor: default;
  opacity: 0.45;
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
::selection {
  background: #ffd2bf;
  color: var(--ink);
}

/* Buttons: an ink one for the step a page is about, quiet edged ones beside it. */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 40px;
  padding: 8px 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: transparent;
  font-size: 14px;
  font-weight: 500;
  line-height: var(--lh-heading);
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 0.15s,
    border-color 0.15s,
    color 0.15s;
}
.button:hover:not(:disabled) {
  border-color: var(--ink);
}
.button.primary {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--page-paper);
}
.button.primary:hover:not(:disabled) {
  border-color: var(--ink-soft);
  background: var(--ink-soft);
}
.button.small {
  min-height: 36px;
  padding: 8px 12px;
}
.button.big {
  min-height: 48px;
  padding: 12px 24px;
  font-size: 15px;
}
.button.block {
  width: 100%;
}
.button svg {
  flex: none;
  width: 18px;
  height: 18px;
}
/* The pressed button spins while its request runs and while the next page loads. */
.button.busy {
  position: relative;
  color: transparent;
}
.button.busy:disabled {
  opacity: 1;
}
.button.busy svg {
  visibility: hidden;
}
.button.busy::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border: 2px solid var(--line-strong);
  border-top-color: var(--ink);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
.button.primary.busy::after {
  border-color: color-mix(in srgb, var(--page-paper) 30%, transparent);
  border-top-color: var(--page-paper);
}
.link {
  padding: 2px 0;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 14px;
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
  text-underline-offset: 3px;
}
.link:hover {
  color: var(--ink);
  text-decoration-color: currentColor;
}

/* Fields: a label in small text over an edged box that takes the accent while typed in. */
.field {
  display: block;
  margin: 0 0 var(--space-4);
}
.field > span {
  display: block;
  margin: 0 0 var(--space-2);
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}
.field :is(input, select) {
  display: block;
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--page-paper);
  outline: none;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
}
.field :is(input, select):focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-tint);
}
.field .field-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-3);
  margin: 0 0 var(--space-2);
  font-size: 13px;
}
.field-head label {
  font-weight: 500;
  color: var(--muted);
}
.field-head .link {
  font-size: 13px;
}

/* A status line under a heading, and small print. */
.note {
  margin: 0 0 var(--space-5);
  padding: 12px 16px;
  border-left: 2px solid var(--line-strong);
  background: var(--paper-deep);
  font-size: 13px;
  color: var(--muted);
  text-align: left;
  overflow-wrap: anywhere;
}
.note:empty {
  display: none;
}
.note[data-tone="error"] {
  border-left-color: var(--accent);
  background: var(--accent-tint);
  color: var(--accent-text);
}
.fine {
  margin: 0 0 var(--space-3);
  font-size: 13px;
  color: var(--muted);
}
.fine:empty {
  display: none;
}
.badge {
  display: inline-block;
  padding: 2px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}
.badge.on {
  border-color: transparent;
  background: var(--accent-tint);
  color: var(--accent-text);
}
.loading {
  display: grid;
  place-items: center;
  min-height: 120px;
}
.spinner {
  width: 22px;
  height: 22px;
  border: 2px solid var(--line-strong);
  border-top-color: var(--muted);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* Placeholders while a page's data loads, shaped like what replaces them, so nothing moves when it arrives. */
.skeleton {
  display: block;
  border-radius: var(--radius-xs);
  background: linear-gradient(90deg, var(--paper-deep) 30%, var(--line) 50%, var(--paper-deep) 70%);
  background-size: 300% 100%;
  animation: shimmer 1.4s ease-in-out infinite;
}
.skeleton.title {
  width: 38%;
  height: 14px;
}
.skeleton.text {
  width: 62%;
  height: 10px;
  margin-top: var(--space-2);
}
.skeleton.pill {
  flex: none;
  width: 92px;
  height: 32px;
  border-radius: var(--radius-pill);
}
.skeleton.cell {
  width: 72%;
  height: 11px;
}

@media (max-width: 520px) {
  .button,
  .button.small {
    min-height: 44px;
  }
  .field :is(input, select) {
    height: 44px;
    font-size: 16px;
  }
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
@keyframes shimmer {
  0% {
    background-position: 100% 0;
  }
  100% {
    background-position: 0 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .skeleton,
  .spinner,
  .button.busy::after {
    animation-duration: 2.4s;
  }
}
:root:is(:lang(zh), :lang(ja), :lang(ko)) :is(em, i) {
  font-style: normal;
}
