:root {
  --page: #f4f4f6;
  --section: #ffffff;
  --fill: rgba(118, 118, 128, 0.12);
  --fill-strong: rgba(118, 118, 128, 0.2);
  --hairline: rgba(60, 60, 67, 0.12);
  --ink: #0a0a0a;
  --ink-soft: #6e6e78;
  --ghost: #aeb2ba;
  --accent: #0e15ca;
  --accent-hover: #080d8f;
  --accent-text: #0e15ca;
  --accent-soft: rgba(14, 21, 202, 0.09);
  --on-accent: #ffffff;
  --glass-bg: rgba(255, 255, 255, 0.64);
  --glass-border: rgba(255, 255, 255, 0.8);
  --glass-shadow: 0 0.5rem 2rem rgba(10, 16, 36, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  --popover-shadow: 0 0.75rem 2.5rem rgba(10, 16, 36, 0.16), 0 0 0 1px rgba(10, 16, 36, 0.04);
  --page-tint: rgba(14, 21, 202, 0.07);
  --backdrop: rgba(10, 10, 20, 0.28);
  --viewer-dim: rgba(8, 8, 14, 0.72);
  --radius-section: 1.125rem;
  --radius-card: 1.5rem;
  --radius-control: 0.75rem;
  --radius-pill: 62.5rem;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --page: #0b0b0c;
    --section: #1c1c1e;
    --fill: rgba(118, 118, 128, 0.24);
    --fill-strong: rgba(118, 118, 128, 0.34);
    --hairline: rgba(255, 255, 255, 0.1);
    --ink: #f4f4f6;
    --ink-soft: rgba(235, 235, 245, 0.6);
    --ghost: rgba(235, 235, 245, 0.3);
    --accent-hover: #2a31e0;
    --accent-text: #8f95ff;
    --accent-soft: rgba(143, 149, 255, 0.16);
    --glass-bg: rgba(30, 30, 34, 0.62);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.07);
    --popover-shadow: 0 0.75rem 2.5rem rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.08);
    --page-tint: rgba(90, 98, 255, 0.12);
    --backdrop: rgba(0, 0, 0, 0.5);
    --viewer-dim: rgba(0, 0, 0, 0.82);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --page: #0b0b0c;
  --section: #1c1c1e;
  --fill: rgba(118, 118, 128, 0.24);
  --fill-strong: rgba(118, 118, 128, 0.34);
  --hairline: rgba(255, 255, 255, 0.1);
  --ink: #f4f4f6;
  --ink-soft: rgba(235, 235, 245, 0.6);
  --ghost: rgba(235, 235, 245, 0.3);
  --accent-hover: #2a31e0;
  --accent-text: #8f95ff;
  --accent-soft: rgba(143, 149, 255, 0.16);
  --glass-bg: rgba(30, 30, 34, 0.62);
  --glass-border: rgba(255, 255, 255, 0.1);
  --glass-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  --popover-shadow: 0 0.75rem 2.5rem rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.08);
  --page-tint: rgba(90, 98, 255, 0.12);
  --backdrop: rgba(0, 0, 0, 0.5);
  --viewer-dim: rgba(0, 0, 0, 0.82);
}

:root[data-theme="light"] {
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  line-height: 1.3;
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  background:
    radial-gradient(60rem 40rem at 0% 0%, var(--page-tint), transparent 60%),
    radial-gradient(50rem 36rem at 100% 100%, var(--page-tint), transparent 60%),
    var(--page);
  background-attachment: fixed;
  color: var(--ink);
  font-family: "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 0.9375rem;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

@media (min-width: 769px) and (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  body {
    background: var(--page);
  }

  body::before,
  body::after {
    position: fixed;
    z-index: -1;
    border-radius: 50%;
    background: radial-gradient(closest-side, var(--page-tint), transparent);
    pointer-events: none;
    will-change: transform;
    content: "";
  }

  body::before {
    top: -40rem;
    left: -60rem;
    width: 120rem;
    height: 80rem;
    animation: page-drift-a 48s ease-in-out infinite alternate;
  }

  body::after {
    right: -50rem;
    bottom: -36rem;
    width: 100rem;
    height: 72rem;
    animation: page-drift-b 56s ease-in-out infinite alternate;
  }
}

@keyframes page-drift-a {
  50% {
    transform: translate(18vw, 10vh);
  }

  100% {
    transform: translate(6vw, 26vh);
  }
}

@keyframes page-drift-b {
  50% {
    transform: translate(-16vw, -12vh);
  }

  100% {
    transform: translate(-4vw, -28vh);
  }
}

body.menu-opened {
  overflow: hidden;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: none;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

[hidden] {
  display: none !important;
}

@view-transition {
  navigation: auto;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 160ms;
}

.sidebar {
  view-transition-name: sidebar;
}

.toolbar {
  view-transition-name: toolbar;
}

.workspace {
  view-transition-name: workspace;
}

::view-transition {
  pointer-events: none;
}

::view-transition-group(workspace),
::view-transition-group(sidebar),
::view-transition-group(toolbar),
::view-transition-group(view-seg),
::view-transition-group(tabbar),
::view-transition-group(detail),
::view-transition-new(sidebar),
::view-transition-new(toolbar),
::view-transition-new(view-seg),
::view-transition-new(tabbar),
::view-transition-new(detail) {
  animation: none;
}

::view-transition-old(sidebar),
::view-transition-old(toolbar),
::view-transition-old(view-seg),
::view-transition-old(tabbar),
::view-transition-old(detail) {
  display: none;
}

::view-transition-old(workspace) {
  translate: 0 var(--vt-shift, 0px);
  animation: view-out 120ms var(--ease-out) both;
}

::view-transition-new(workspace) {
  animation: view-in 180ms var(--ease-out) both;
}

@keyframes view-out {
  to {
    opacity: 0;
  }
}

@keyframes view-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
}

@keyframes view-fade {
  from {
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  @view-transition {
    navigation: none;
  }

  ::view-transition-new(workspace) {
    animation: view-fade 120ms var(--ease-out) both;
  }
}

:focus {
  outline: none;
}

:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}

.ts-wrapper .ts-control:focus-visible,
.ts-wrapper .ts-control:focus,
.ts-wrapper.focus .ts-control,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[contenteditable]:focus-visible {
  box-shadow: none;
}

.ph {
  font-size: 1.125rem;
  line-height: 1;
}

.glass {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  backdrop-filter: blur(24px) saturate(180%);
}

@media (display-mode: standalone) and (max-width: 768px) {
  .glass {
    background: color-mix(in srgb, var(--page) 90%, transparent);
  }
}

@media (prefers-reduced-transparency: reduce) {
  .glass {
    background: var(--section);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

.page {
  display: grid;
  grid-template-columns: 17rem minmax(0, 1fr);
  gap: 1rem;
  padding: 0.75rem;
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0.75rem;
  height: calc(100vh - 1.5rem);
  height: calc(100dvh - 1.5rem);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  overflow-y: auto;
  border-radius: var(--radius-card);
  padding: 1.25rem 0.625rem 0.75rem;
}

.sidebar-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 0.75rem;
}

.sidebar-brand {
  font-size: 1.25rem;
  font-weight: 500;
  letter-spacing: -0.04em;
}

.sidebar-brand span {
  color: var(--accent-text);
}

.page .sidebar-close,
.page .btn-menu {
  display: none;
}

.sidebar-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--ink-soft);
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 0 0.25rem 0 0.75rem;
  margin-bottom: 0.25rem;
}

.sidebar-title .icon-btn {
  width: 1.75rem;
  height: 1.75rem;
  background: transparent;
  color: var(--accent-text);
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0.0625rem;
}

.sidebar-nav button,
.sidebar-nav a,
.sidebar-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  min-height: 2.25rem;
  padding: 0.375rem 0.75rem;
  border-radius: var(--radius-control);
  text-align: left;
  transition: background-color 150ms ease, color 150ms ease;
}

.sidebar-link {
  justify-content: flex-start;
  gap: 0.625rem;
  color: var(--ink-soft);
}

.sidebar-link.has-update {
  color: var(--accent-text);
}

.link-hint {
  margin-left: auto;
  color: var(--ghost);
  font-size: 0.75rem;
}

.sidebar-link.has-update::after {
  content: "";
  flex: none;
  margin-left: auto;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--accent);
}

.sidebar-nav .nav-label {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  min-width: 0;
  font-weight: inherit;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-nav .nav-label .ph {
  color: var(--accent-text);
}

.sidebar-nav .nav-label i:not(.ph) {
  flex: none;
  width: 0.375rem;
  height: 0.875rem;
  border-radius: 0.125rem;
  background: var(--tag);
}

.sidebar-nav button > span,
.sidebar-nav a > span {
  color: var(--ink-soft);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}

.sidebar-nav button.level-1 {
  padding-left: 1.75rem;
}

.sidebar-nav button.level-2 {
  padding-left: 2.75rem;
}

@media (hover: hover) and (pointer: fine) {
  .sidebar-nav button:hover,
  .sidebar-nav a:hover,
  .sidebar-link:hover {
    background: var(--fill);
  }

  .sidebar-link:hover {
    color: var(--ink);
  }
}

.sidebar-nav button.active {
  background: var(--accent-soft);
  color: var(--accent-text);
  font-weight: 500;
}

.sidebar-nav button.active > span {
  color: var(--accent-text);
}

.sidebar-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.segmented {
  position: relative;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  padding: 0.125rem;
  border-radius: var(--radius-pill);
  background: var(--fill);
  isolation: isolate;
}

.segmented.inline {
  display: inline-grid;
  grid-auto-columns: auto;
}

.segmented > a,
.segmented > button {
  position: relative;
  z-index: 1;
  padding: 0.375rem 0.875rem;
  border-radius: var(--radius-pill);
  font-size: 0.875rem;
  text-align: center;
  white-space: nowrap;
  color: var(--ink);
}

.segmented > a span,
.segmented > button span {
  color: var(--ink-soft);
  margin-left: 0.25rem;
  font-variant-numeric: tabular-nums;
}

.segmented-thumb {
  position: absolute;
  z-index: 0;
  top: 0.125rem;
  bottom: 0.125rem;
  left: 0;
  border-radius: var(--radius-pill);
  background: var(--section);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 0 0 0.5px rgba(0, 0, 0, 0.04);
  transition: transform 200ms var(--ease-in-out);
}

.segmented.no-motion .segmented-thumb {
  transition: none;
}

.sidebar-modules {
  margin: 0 0.25rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  min-height: 2.75rem;
  padding: 0.5rem 1.125rem;
  border-radius: var(--radius-pill);
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 500;
  white-space: nowrap;
  transition: background-color 150ms ease, transform 120ms var(--ease-out);
}

.btn:active,
.icon-btn:active,
.chip-btn:active {
  transform: scale(0.97);
}

.chip-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  min-height: 2.25rem;
  padding: 0 0.875rem;
  border-radius: var(--radius-pill);
  background: var(--fill);
  color: var(--ink);
  font-size: 0.875rem;
  white-space: nowrap;
  transition: background-color 150ms ease, color 150ms ease, transform 120ms var(--ease-out);
}

.chip-btn.active {
  background: var(--accent-soft);
  color: var(--accent-text);
}

.btn-ghost {
  background: var(--fill);
  color: var(--ink);
  font-weight: 400;
}

.btn-danger {
  background: transparent;
  color: #d93036;
  font-weight: 400;
}

.btn-small {
  min-height: 2.25rem;
  padding: 0.25rem 1rem;
  font-size: 0.875rem;
}

@media (hover: hover) and (pointer: fine) {
  .btn:hover {
    background: var(--accent-hover);
  }

  .btn-ghost:hover {
    background: var(--fill-strong);
  }

  .btn-danger:hover {
    background: rgba(217, 48, 54, 0.08);
  }
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius-pill);
  background: var(--fill);
  color: var(--ink);
  transition: background-color 150ms ease, transform 120ms var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
  .icon-btn:hover {
    background: var(--fill-strong);
  }
}

.sidebar-overlay {
  display: none;
}

.workspace {
  min-width: 0;
  padding: 0 0.75rem 4rem;
}

.toolbar {
  position: sticky;
  top: 0.75rem;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem;
  border-radius: var(--radius-pill);
  margin-bottom: 1.5rem;
}

.toolbar .btn {
  min-height: 2.25rem;
  padding: 0.25rem 1rem;
}

.search {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.25rem;
  padding: 0 0.875rem;
  border-radius: var(--radius-pill);
  background: var(--fill);
  color: var(--ink-soft);
}

.search input {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  color: var(--ink);
  outline: none;
}

.search input::placeholder {
  color: var(--ink-soft);
}

.workspace-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin: 0 0.25rem 1rem;
}

.workspace-title {
  font-size: 2.125rem;
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.05;
}

.workspace-count {
  color: var(--ghost);
}

.tabs {
  margin: 0 0.25rem 1.25rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.section {
  background: var(--section);
  border-radius: var(--radius-section);
  overflow: hidden;
}

.caption {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  min-height: 2rem;
  padding: 1.25rem 1rem 0.375rem;
  color: var(--ink-soft);
  font-size: 0.8125rem;
}

.caption:first-child {
  padding-top: 0;
}

.caption button {
  color: var(--accent-text);
  font-size: 0.8125rem;
}

.row-note {
  margin-left: 0.5rem;
  color: var(--ghost);
  font-size: 0.8125rem;
  font-weight: 400;
}

.list-empty,
.section-empty {
  color: var(--ink-soft);
  text-align: center;
  padding: 3.5rem 1rem;
  line-height: 1.45;
}

.section-empty {
  padding: 1rem;
  text-align: left;
}

.row,
.task {
  position: relative;
  display: grid;
  grid-template-columns: 1.25rem minmax(0, 1fr) auto;
  align-items: start;
  column-gap: 0.875rem;
  padding: 0.75rem 1rem;
  cursor: pointer;
  transition: background-color 150ms ease;
}

.row {
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
}

.row.no-lead {
  grid-template-columns: minmax(0, 1fr) auto;
}

.row + .row::before,
.task + .task::before {
  content: "";
  position: absolute;
  top: 0;
  left: 3.125rem;
  right: 0;
  height: 1px;
  background: var(--hairline);
}

.row.no-lead + .row.no-lead::before {
  left: 1rem;
}

@media (hover: hover) and (pointer: fine) {
  .row:hover,
  .task:hover {
    background: var(--fill);
  }
}

.row-lead {
  display: grid;
  place-items: center;
  width: 1.25rem;
  color: var(--ink-soft);
}

.row-lead i:not(.ph) {
  width: 0.375rem;
  height: 1.125rem;
  border-radius: 0.125rem;
  background: var(--tag);
}

.row-title {
  overflow-wrap: anywhere;
}

.row-sub {
  margin-top: 0.125rem;
  color: var(--ink-soft);
  font-size: 0.8125rem;
  overflow-wrap: anywhere;
}

.row-side {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--ink-soft);
  font-size: 0.8125rem;
  white-space: nowrap;
}

.row-side a,
.row-side button.link {
  display: inline-grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  color: var(--accent-text);
}

.row-add {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  width: 100%;
  padding: 0.75rem 1rem;
  color: var(--accent-text);
  text-align: left;
}

.row + .row-add,
.task + .row-add {
  border-top: 1px solid var(--hairline);
}

.badge {
  display: inline-block;
  padding: 0.125rem 0.5rem;
  border-radius: var(--radius-pill);
  background: var(--fill);
  color: var(--ink);
  font-size: 0.75rem;
}

.badge.accent {
  background: var(--accent-soft);
  color: var(--accent-text);
}

.field-row {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 2.875rem;
  padding: 0.375rem 1rem;
}

.field-row + .field-row::before {
  content: "";
  position: absolute;
  top: 0;
  left: 1rem;
  right: 0;
  height: 1px;
  background: var(--hairline);
}

.field-row > span,
.field-row > label {
  flex: none;
  color: var(--ink);
}

.field-row > input,
.field-row > textarea {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  color: var(--ink);
  text-align: right;
  outline: none;
}

.field-row input::placeholder,
.field-row textarea::placeholder {
  color: var(--ghost);
}

.field-row .ts-wrapper {
  flex: 1;
  max-width: 17rem;
}

.field-row .ts-wrapper .ts-control {
  background: transparent;
  justify-content: flex-end;
  padding-left: 0.25rem;
}

.field-row .ts-wrapper .ts-control .item {
  text-align: right;
}

.field-row.stack {
  flex-direction: column;
  align-items: stretch;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
}

.field-row.stack > input {
  text-align: left;
}

.field-row .segmented {
  flex: 1;
}

.field-error {
  padding: 0.375rem 1rem 0;
  color: #d93036;
  font-size: 0.8125rem;
}

.field-hint {
  padding: 0.5rem 1rem 0;
  color: var(--ink-soft);
  font-size: 0.8125rem;
  line-height: 1.4;
}

.field-hint.good {
  color: var(--ink);
}

.field-hint.warn {
  color: #d93036;
}

.swatches {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.375rem;
}

.swatch {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: var(--radius-pill);
  background: var(--c);
  transition: box-shadow 150ms ease;
}

.swatch.active {
  box-shadow: 0 0 0 2px var(--section), 0 0 0 3.5px var(--c);
}

.sheet {
  width: min(32rem, calc(100vw - 2rem));
  max-height: min(48rem, calc(100dvh - 2rem));
  margin: auto;
  padding: 0;
  border: none;
  border-radius: 1.75rem;
  background: var(--page);
  color: var(--ink);
  box-shadow: var(--popover-shadow);
  overflow: visible;
}

.sheet[open] {
  display: flex;
  flex-direction: column;
}

.sheet-form {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  max-height: inherit;
  border-radius: inherit;
  overflow: hidden;
}

.sheet::backdrop {
  background: var(--backdrop);
  transition: opacity 250ms var(--ease-out);
}

@starting-style {
  .sheet[open]::backdrop {
    opacity: 0;
  }
}

.sheet-head {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 0.875rem 0.5rem;
}

.sheet-head h2 {
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
}

.sheet-cancel {
  justify-self: start;
  padding: 0.375rem 0.625rem;
  border-radius: var(--radius-pill);
  color: var(--accent-text);
}

.sheet-head .btn {
  justify-self: end;
  min-height: 2.25rem;
  padding: 0.25rem 1rem;
}

.sheet-body {
  overflow-y: auto;
  padding: 0.5rem 1rem 1.25rem;
}

.sheet-body .caption {
  padding-left: 1rem;
}

.sheet-foot {
  display: flex;
  justify-content: center;
  padding-top: 1rem;
}

.steps {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem;
  line-height: 1.45;
}

.steps li {
  display: grid;
  grid-template-columns: 1.75rem 1fr;
  gap: 0.5rem;
  list-style: none;
}

.steps .ph {
  color: var(--accent-text);
  font-size: 1.25rem;
}

.install-head {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 0.25rem 0.25rem 1rem;
}

.install-icon {
  flex: none;
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 0.875rem;
  box-shadow: 0 0 0 1px var(--hairline);
}

.install-head b {
  display: block;
  font-weight: 500;
}

.install-head span {
  display: block;
  margin-top: 0.125rem;
  color: var(--ink-soft);
  font-size: 0.8125rem;
  line-height: 1.4;
}

.install-stage {
  height: 13.5rem;
  border-radius: var(--radius-section);
  background: var(--fill);
  overflow: hidden;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}

.install-track {
  display: flex;
  height: 100%;
  transition: transform 320ms var(--ease-drawer);
}

.install-track.dragging {
  transition: none;
}

.install-art {
  flex: none;
  width: 100%;
  height: 100%;
  display: grid;
  place-items: end center;
}

.install-caption {
  min-height: 5.5rem;
  padding: 1rem 0.25rem 0;
}

.install-step-title {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
  font-weight: 500;
  line-height: 1.4;
}

.install-step-title span {
  flex: none;
  display: grid;
  place-items: center;
  width: 1.375rem;
  height: 1.375rem;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 0.75rem;
}

.install-caption .field-hint {
  padding: 0.375rem 0 0 2rem;
}

.install-dots {
  display: flex;
  justify-content: center;
  gap: 0.375rem;
  margin: 0.25rem 0 1rem;
}

.install-dots button {
  width: 0.4375rem;
  height: 0.4375rem;
  border-radius: var(--radius-pill);
  background: var(--fill-strong);
  transition: width 200ms var(--ease-out), background-color 200ms var(--ease-out);
}

.install-dots button.active {
  width: 1.25rem;
  background: var(--accent);
}

.install-nav {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 0.625rem;
}

.install-nav .btn:disabled {
  opacity: 0.4;
  cursor: default;
}

.ios-hl {
  border-radius: 0.625rem;
  color: var(--accent-text);
  animation: install-pulse 1.6s var(--ease-in-out) infinite;
}

@keyframes install-pulse {
  0%, 100% { box-shadow: 0 0 0 2px var(--accent-text), 0 0 0 4px transparent; }
  50% { box-shadow: 0 0 0 2px var(--accent-text), 0 0 0 7px var(--accent-soft); }
}

.ios-screen {
  display: flex;
  flex-direction: column;
  width: 13.5rem;
  height: 11.75rem;
  border: 1px solid var(--hairline);
  border-bottom: 0;
  border-radius: 1.625rem 1.625rem 0 0;
  background: var(--section);
  color: var(--ink);
  overflow: hidden;
}

.ios-page {
  flex: 1;
  display: grid;
  align-content: start;
  gap: 0.5rem;
  padding: 1rem 1rem 0;
}

.ios-line {
  height: 0.4375rem;
  border-radius: 0.25rem;
  background: var(--fill);
}

.ios-line.w60 { width: 60%; }
.ios-line.w70 { width: 70%; }
.ios-line.w90 { width: 90%; }

.ios-block {
  height: 2.75rem;
  border-radius: 0.625rem;
  background: var(--accent-soft);
}

.ios-toolbar {
  padding: 0.5rem 0.625rem 0.75rem;
  border-top: 1px solid var(--hairline);
  background: var(--page);
}

.ios-address {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.25rem;
  margin-bottom: 0.5rem;
  padding: 0.3125rem 0.5rem;
  border-radius: 0.5625rem;
  background: var(--fill);
  color: var(--ink-soft);
  font-size: 0.625rem;
  white-space: nowrap;
}

.ios-address .ph {
  font-size: 0.625rem;
}

.ios-icons {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--accent-text);
}

.ios-icons .ph {
  font-size: 1.125rem;
}

.ios-icons .ios-off {
  opacity: 0.35;
}

.ios-icons .ios-hl {
  display: grid;
  place-items: center;
  width: 1.875rem;
  height: 1.875rem;
}

.ios-screen.dim {
  justify-content: flex-end;
  background: var(--fill-strong);
}

.ios-menu {
  margin: 0 0.625rem;
  padding: 0.25rem 0;
  border-radius: 0.875rem 0.875rem 0 0;
  background: var(--section);
}

.ios-menu-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5625rem 0.75rem;
  border-bottom: 1px solid var(--hairline);
  font-size: 0.6875rem;
}

.ios-menu-row:last-child {
  border-bottom: 0;
}

.ios-menu-row .ph {
  font-size: 1rem;
}

.ios-menu-row.ios-hl {
  position: relative;
  margin: 0 0.25rem;
  background: var(--section);
  color: var(--ink);
  font-weight: 500;
}

.ios-dialog-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.375rem;
  padding: 0.875rem 0.625rem 0.75rem;
  border-bottom: 1px solid var(--hairline);
  color: var(--accent-text);
  font-size: 0.625rem;
}

.ios-dialog-top b {
  flex: 1;
  min-width: 0;
  color: var(--ink);
  font-size: 0.5625rem;
  font-weight: 500;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ios-add {
  flex: none;
  padding: 0.1875rem 0.375rem;
  font-weight: 500;
}

.ios-dialog-card {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  margin: 0.875rem 0.75rem;
}

.ios-dialog-card img {
  border-radius: 0.6875rem;
  box-shadow: 0 0 0 1px var(--hairline);
}

.ios-dialog-card > div {
  flex: 1;
  min-width: 0;
}

.ios-dialog-name {
  padding-bottom: 0.3125rem;
  border-bottom: 1px solid var(--hairline);
  font-size: 0.8125rem;
  font-weight: 500;
}

.ios-dialog-url {
  margin-top: 0.3125rem;
  color: var(--ink-soft);
  font-size: 0.625rem;
}

@media (prefers-reduced-motion: reduce) {
  .ios-hl {
    animation: none;
    box-shadow: 0 0 0 2px var(--accent-text);
  }

  .install-track,
  .install-dots button {
    transition: none;
  }
}

.toast {
  --drag: 0px;
  position: fixed;
  left: 0;
  right: 0;
  bottom: max(1.25rem, env(safe-area-inset-bottom));
  z-index: 600;
  display: flex;
  align-items: center;
  gap: 0.625rem;
  width: max-content;
  max-width: min(30rem, calc(100% - 2rem));
  margin-inline: auto;
  padding: 0.75rem 1.25rem 0.75rem 1rem;
  border-radius: 1.375rem;
  color: var(--ink);
  opacity: 0;
  transform: translateY(calc(1rem + var(--drag)));
  pointer-events: none;
  touch-action: none;
  transition: opacity 200ms var(--ease-out), transform 300ms var(--ease-out);
}

.toast.visible {
  opacity: 1;
  transform: translateY(var(--drag));
  pointer-events: auto;
}

.toast.dragging {
  transition: none;
}

.toast-icon {
  flex: none;
  color: #30a46c;
  font-size: 1.25rem;
}

.toast.error .toast-icon {
  color: #e5484d;
}

.toast-icon.toast-muted {
  color: var(--ink-soft);
}

.toast.with-action .toast-icon {
  color: var(--ink-soft);
}

.toast-text {
  flex: 1;
  min-width: 0;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.toast.with-action {
  padding: 0.375rem 0.375rem 0.375rem 1rem;
}

.toast button {
  flex: none;
  min-height: 2.25rem;
  padding: 0 1rem;
  border-radius: var(--radius-pill);
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 500;
}

.swiping {
  position: relative;
  z-index: 1;
  background: var(--section);
  touch-action: pan-y;
  will-change: transform;
}

.swipe-under {
  --p: 0;
  position: absolute;
  left: 0;
  right: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.swipe-act {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 1.5rem;
  background: color-mix(in srgb, var(--swipe) calc(35% + var(--p) * 40%), var(--section));
  color: #ffffff;
  opacity: 0;
  transition: background-color 160ms ease;
}

.swipe-act.left {
  justify-content: flex-end;
}

.swipe-under[data-side="left"] .swipe-act.left,
.swipe-under[data-side="right"] .swipe-act.right {
  opacity: 1;
}

.swipe-act .ph {
  font-size: 1.5rem;
  transform: scale(calc(0.55 + var(--p) * 0.45)) rotate(calc((1 - var(--p)) * -25deg));
  transition: transform 90ms linear;
}

.swipe-act b {
  font-size: 0.8125rem;
  font-weight: 500;
  opacity: var(--p);
}

.swipe-under.armed .swipe-act {
  background: var(--swipe);
}

.swipe-under.armed .swipe-act .ph {
  animation: swipe-pop 420ms cubic-bezier(0.34, 1.56, 0.64, 1) both, swipe-wiggle 520ms 180ms ease-in-out;
}

.swipe-under.gulp .swipe-act .ph {
  animation: swipe-gulp 380ms cubic-bezier(0.36, 0, 0.66, -0.56) forwards;
}

@keyframes swipe-pop {
  0% { transform: scale(1); }
  45% { transform: scale(1.45); }
  100% { transform: scale(1.18); }
}

@keyframes swipe-wiggle {
  0%, 100% { rotate: 0deg; }
  25% { rotate: -14deg; }
  50% { rotate: 11deg; }
  75% { rotate: -6deg; }
}

@keyframes swipe-gulp {
  0% { transform: scale(1.18); }
  35% { transform: scale(1.6) rotate(-12deg); }
  100% { transform: scale(0) rotate(40deg); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .swipe-under.armed .swipe-act .ph,
  .swipe-under.gulp .swipe-act .ph {
    animation: none;
  }
}

.ts-wrapper {
  position: relative;
  min-width: 8rem;
}

.ts-wrapper .ts-control {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  min-height: 2.25rem;
  padding: 0.25rem 2rem 0.25rem 0.875rem;
  border: none;
  border-radius: var(--radius-pill);
  background: var(--fill);
  color: var(--ink);
  font-size: inherit;
  line-height: inherit;
  cursor: pointer;
  overflow: hidden;
}

.ts-wrapper .ts-control::after {
  content: "";
  position: absolute;
  right: 0.875rem;
  top: 50%;
  width: 0.375rem;
  height: 0.375rem;
  border: solid var(--ink-soft);
  border-width: 0 1.5px 1.5px 0;
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

.ts-wrapper.focus .ts-control {
  box-shadow: inset 0 0 0 1.5px var(--accent-text);
}

.ts-wrapper .ts-control > input {
  flex: 1;
  min-width: 2rem;
  border: none;
  background: transparent;
  color: var(--ink);
  font-size: inherit;
  outline: none;
}

.ts-wrapper .ts-control > input::placeholder {
  color: var(--ink-soft);
}

.ts-wrapper.has-items .ts-control > input:not(:focus) {
  position: absolute;
  opacity: 0;
  width: 1px;
}

.ts-wrapper .ts-control .item {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ts-dropdown {
  position: absolute;
  z-index: 400;
  min-width: 100%;
  width: max-content;
  max-width: min(22rem, 90vw);
  margin-top: 0.375rem;
  padding: 0.25rem;
  border-radius: 1.125rem;
  background: var(--section);
  box-shadow: var(--popover-shadow);
  color: var(--ink);
  transform-origin: top center;
  transition: opacity 180ms var(--ease-out), transform 180ms var(--ease-out);
}

@starting-style {
  .ts-dropdown {
    opacity: 0;
    transform: scale(0.97) translateY(-0.25rem);
  }
}

.field-row .ts-dropdown,
.prop .ts-dropdown {
  left: auto !important;
  right: 0;
  transform-origin: top right;
}

.ts-dropdown .ts-dropdown-content {
  max-height: 18rem;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  scroll-behavior: auto;
}

.ts-dropdown .option,
.ts-dropdown .no-results,
.ts-dropdown .optgroup-header {
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.9375rem;
  cursor: pointer;
}

.ts-dropdown .optgroup-header {
  color: var(--ink-soft);
  font-size: 0.75rem;
  cursor: default;
}

.ts-dropdown .option.active {
  background: var(--accent-soft);
  color: var(--accent-text);
}

.ts-dropdown .option.selected {
  font-weight: 500;
}

.ts-dropdown .no-results {
  color: var(--ink-soft);
}

.ts-dropdown [data-selectable] .highlight {
  background: var(--accent-soft);
  border-radius: 0.125rem;
}

.ts-hidden-accessible {
  border: 0 !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  overflow: hidden !important;
  padding: 0 !important;
  position: absolute !important;
  width: 1px !important;
  white-space: nowrap !important;
}

.native-pick-host {
  position: relative;
}

.native-pick {
  position: absolute;
  inset: 0;
  z-index: 3;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: none;
  opacity: 0;
  font-size: 1rem;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}

.pick-search {
  margin: 0 0 0.75rem;
}

[data-pick-list] {
  min-height: 45dvh;
}

.pick-row {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  width: 100%;
  text-align: left;
}

.pick-row .pick-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
}

.pick-row > .ph-check {
  color: var(--accent-text);
}

.date-input {
  cursor: pointer;
  caret-color: transparent;
}

.air-datepicker {
  --adp-font-family: inherit;
  --adp-font-size: 0.875rem;
  --adp-width: 17rem;
  --adp-z-index: 700;
  --adp-padding: 0.5rem;
  --adp-transition-duration: 180ms;
  --adp-transition-ease: cubic-bezier(0.23, 1, 0.32, 1);
  --adp-transition-offset: 6px;
  --adp-background-color: var(--section);
  --adp-background-color-hover: var(--fill);
  --adp-background-color-active: var(--fill-strong);
  --adp-background-color-in-range: var(--accent-soft);
  --adp-background-color-in-range-focused: var(--fill-strong);
  --adp-background-color-selected-other-month-focused: var(--accent-hover);
  --adp-background-color-selected-other-month: var(--accent);
  --adp-color: var(--ink);
  --adp-color-secondary: var(--ink-soft);
  --adp-accent-color: var(--accent-text);
  --adp-color-current-date: var(--accent-text);
  --adp-color-other-month: var(--ghost);
  --adp-color-disabled: var(--ghost);
  --adp-color-disabled-in-range: var(--ghost);
  --adp-color-other-month-hover: var(--ink-soft);
  --adp-border-color: transparent;
  --adp-border-color-inner: var(--hairline);
  --adp-border-radius: 0.875rem;
  --adp-border-color-inline: transparent;
  --adp-nav-height: 2.25rem;
  --adp-nav-arrow-color: var(--ink-soft);
  --adp-nav-action-size: 2rem;
  --adp-nav-color-secondary: var(--ink-soft);
  --adp-day-name-color: var(--ink-soft);
  --adp-day-name-color-hover: var(--ink);
  --adp-day-cell-height: 2.125rem;
  --adp-month-cell-height: 2.625rem;
  --adp-year-cell-height: 3.5rem;
  --adp-pointer-size: 0px;
  --adp-cell-border-radius: 0.5rem;
  --adp-cell-background-color-selected: var(--accent);
  --adp-cell-background-color-selected-hover: var(--accent-hover);
  --adp-cell-background-color-in-range: var(--accent-soft);
  --adp-cell-background-color-in-range-hover: var(--fill-strong);
  --adp-cell-border-color-in-range: var(--accent);
  --adp-btn-height: 2rem;
  --adp-btn-color: var(--accent-text);
  --adp-btn-color-hover: var(--accent-text);
  --adp-btn-border-radius: var(--radius-pill);
  --adp-btn-background-color-hover: var(--accent-soft);
  --adp-btn-background-color-active: var(--fill-strong);
  --adp-mobile-font-size: 1rem;
  --adp-mobile-nav-height: 2.75rem;
  --adp-mobile-width: 20rem;
  --adp-mobile-day-cell-height: 2.75rem;
  box-shadow: var(--popover-shadow);
}

.air-datepicker-cell.-selected-,
.air-datepicker-cell.-selected-.-current- {
  color: #ffffff;
}

.air-datepicker--pointer {
  display: none;
}

.air-datepicker-body {
  touch-action: pan-y;
}

.air-datepicker--content {
  overflow: hidden;
}

.field-row > input.time-native {
  flex: none;
  width: auto;
  min-width: 5.5rem;
  min-height: 2rem;
  padding: 0 0.625rem;
  border: none;
  border-radius: var(--radius-control);
  background: var(--fill);
  color: var(--ink);
  font: inherit;
  text-align: right;
}

.air-datepicker-overlay {
  --adp-overlay-z-index: 690;
  --adp-overlay-background-color: var(--backdrop);
}

@media (max-width: 992px) {
  .page {
    display: block;
    padding: 0.5rem;
  }

  .sidebar {
    position: fixed;
    top: max(0.5rem, env(safe-area-inset-top));
    left: 0.5rem;
    bottom: 0.5rem;
    z-index: 100;
    width: min(19rem, calc(100vw - 3rem));
    height: auto;
    transform: translateX(calc(-100% - 1rem));
    visibility: hidden;
    transition: transform 200ms var(--ease-out), visibility 0s 200ms;
  }

  .sidebar.opened {
    transform: none;
    visibility: visible;
    transition: transform 320ms var(--ease-drawer);
  }

  .page .sidebar-close,
  .page .btn-menu {
    display: inline-grid;
  }

  .sidebar-overlay {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 90;
    background: var(--backdrop);
    opacity: 0;
    pointer-events: none;
    transition: opacity 250ms var(--ease-out);
  }

  .sidebar-overlay.visible {
    opacity: 1;
    pointer-events: auto;
  }

  .workspace {
    padding: 0 0 4rem;
  }

  .toolbar {
    top: max(0.5rem, env(safe-area-inset-top));
  }
}

@media (max-width: 768px) {
  .workspace-title,
  .entity-name {
    font-size: 1.625rem;
  }

  .workspace-head {
    align-items: flex-start;
  }

  .toolbar .btn-label {
    display: none;
  }

  .sheet {
    width: 100%;
    max-width: none;
    max-height: calc(100dvh - 2.5rem);
    margin: auto 0 0;
    border-radius: 1.75rem 1.75rem 0 0;
    padding-bottom: env(safe-area-inset-bottom);
  }
}

@media (prefers-reduced-motion: reduce) {
  .sidebar,
  .sidebar.opened,
  .detail,
  .detail.opened {
    transition-property: visibility, opacity;
  }

  .segmented-thumb,
  .ts-dropdown {
    transition-property: opacity;
  }

  .toast,
  .toast.visible {
    transform: translateY(var(--drag));
  }

  .btn:active,
  .icon-btn:active,
  .chip-btn:active {
    transform: none;
  }
}

.switch {
  position: relative;
  flex: none;
  width: 3.125rem;
  height: 1.875rem;
  border-radius: var(--radius-pill);
  background: var(--fill-strong);
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
  transition: background-color 200ms ease;
}

.switch::after {
  content: "";
  position: absolute;
  top: 0.125rem;
  left: 0.125rem;
  width: 1.625rem;
  height: 1.625rem;
  border-radius: var(--radius-pill);
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
  transition: transform 200ms var(--ease-out);
}

.field-row > .switch {
  flex: none;
}

.switch:checked {
  background: var(--accent);
}

.switch:checked::after {
  transform: translateX(1.25rem);
}

@media (prefers-reduced-motion: reduce) {
  .switch::after {
    transition: none;
  }
}

.mark {
  position: relative;
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 0.375rem;
  background: var(--tag);
  color: #ffffff;
  font-size: 0.6875rem;
  font-weight: 500;
  line-height: 1;
  overflow: hidden;
}

.mark b {
  font-weight: 500;
}

.mark img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #ffffff;
  padding: 8%;
}

.mark.has-logo b {
  visibility: hidden;
}

.mark.mid {
  width: 2rem;
  height: 2rem;
  border-radius: 0.5rem;
  font-size: 0.9375rem;
}

.mark.big {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 0.875rem;
  font-size: 1.5rem;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.06);
}

.alert {
  width: min(18rem, calc(100vw - 3rem));
  margin: auto;
  padding: 0;
  border: none;
  border-radius: 1.25rem;
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  backdrop-filter: blur(30px) saturate(180%);
  color: var(--ink);
  box-shadow: var(--popover-shadow);
  text-align: center;
  overflow: hidden;
}

.alert::backdrop {
  background: var(--backdrop);
}

.alert-body {
  padding: 1.25rem 1.25rem 1rem;
}

.alert-body h2 {
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.3;
}

.alert-body p {
  margin-top: 0.375rem;
  color: var(--ink-soft);
  font-size: 0.8125rem;
  line-height: 1.4;
}

.alert-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--hairline);
}

.alert-actions button {
  min-height: 2.875rem;
  color: var(--accent-text);
}

.alert-actions button + button {
  border-left: 1px solid var(--hairline);
}

.alert-actions .danger {
  color: #d93036;
  font-weight: 500;
}

.alert-actions .primary {
  font-weight: 500;
}

@media (hover: hover) and (pointer: fine) {
  .alert-actions button:hover {
    background: var(--fill);
  }
}

.popmenu {
  position: fixed;
  z-index: 800;
  min-width: 13rem;
  max-width: min(20rem, calc(100vw - 1rem));
  padding: 0.25rem;
  border-radius: 1.125rem;
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  backdrop-filter: blur(30px) saturate(180%);
  box-shadow: var(--popover-shadow);
  color: var(--ink);
  transition: opacity 150ms var(--ease-out), transform 150ms var(--ease-out);
}

@starting-style {
  .popmenu {
    opacity: 0;
    transform: scale(0.96);
  }
}

.popmenu.closing {
  opacity: 0;
  transform: scale(0.98);
  transition-duration: 110ms;
}

.popmenu button {
  display: grid;
  grid-template-columns: 1.25rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.4375rem 0.625rem;
  border-radius: 0.5rem;
  font-size: 0.9375rem;
  text-align: left;
}

.popmenu button > .ph:first-child {
  color: var(--ink-soft);
}

.popmenu button small {
  color: var(--ink-soft);
  font-size: 0.75rem;
}

.popmenu button.checked {
  grid-template-columns: 1.25rem minmax(0, 1fr) auto auto;
}

.popmenu-check {
  color: var(--accent-text);
}

.popmenu button.danger,
.popmenu button.danger .ph {
  color: #d93036;
}

.popmenu button:focus-visible {
  outline: none;
  background: var(--accent-soft);
}

@media (hover: hover) and (pointer: fine) {
  .popmenu button:hover {
    background: var(--accent-soft);
  }
}

.popmenu-sep {
  height: 1px;
  margin: 0.25rem 0.5rem;
  background: var(--hairline);
}

.popmenu-title {
  padding: 0.375rem 0.625rem 0.25rem;
  color: var(--ink-soft);
  font-size: 0.75rem;
}

.sync-row {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.sync-row > .sidebar-link {
  flex: 1;
  min-width: 0;
}

.sync-btn {
  background: transparent;
}

.sync-ico {
  font-size: 1.25rem;
}

[data-sync-state="ok"] .sync-ico {
  color: #30a46c;
}

[data-sync-state="sending"] .sync-ico,
[data-sync-state="offline"] .sync-ico {
  color: var(--ink-soft);
}

[data-sync-state="error"] .sync-ico {
  color: #e5484d;
}

.sync-ico.ph-cloud-arrow-up {
  animation: sync-lift 1.4s var(--ease-in-out) infinite;
}

@keyframes sync-lift {
  0%, 100% { transform: translateY(0.0625rem); opacity: 0.65; }
  50% { transform: translateY(-0.125rem); opacity: 1; }
}

.sync-title {
  display: none;
  align-items: center;
  gap: 0.375rem;
  margin-left: 0.375rem;
  padding: 0.3125rem;
  border-radius: var(--radius-pill);
  color: var(--ink-soft);
  font-size: 0.8125rem;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1;
  vertical-align: 0.25rem;
  transition: background-color 150ms ease;
}

.sync-pop {
  width: 17.5rem;
}

.sync-info {
  display: grid;
  grid-template-columns: 1.25rem minmax(0, 1fr);
  gap: 0.25rem 0.5rem;
  padding: 0.25rem 0.625rem 0.5rem;
}

.sync-info b {
  font-weight: 500;
}

.sync-info span {
  grid-column: 2;
  color: var(--ink-soft);
  font-size: 0.8125rem;
  line-height: 1.4;
}

@media (hover: hover) and (pointer: fine) {
  .sync-title:hover {
    background: var(--fill-strong);
  }
}

@media (max-width: 768px) {
  .sync-btn {
    display: none;
  }

  .sync-title {
    display: inline-flex;
  }
}

@media (prefers-reduced-motion: reduce) {
  .sync-ico.ph-cloud-arrow-up {
    animation: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .popmenu,
  .sub-toggle .ph {
    transition-property: opacity;
  }
}

.sidebar > *,
.sheet > form > .sheet-head {
  flex-shrink: 0;
}

.sheet > form {
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-height: inherit;
}

.field-row .ts-wrapper.focus .ts-control {
  box-shadow: none;
  background: var(--fill);
  border-radius: var(--radius-control);
}

.prop .ts-wrapper .ts-control,
.prop .ts-wrapper.focus .ts-control,
.score-field .ts-wrapper .ts-control,
.score-field .ts-wrapper.focus .ts-control {
  box-shadow: none;
  background: transparent;
  border-radius: var(--radius-pill);
}

.prop,
.score-field {
  transition: background-color 150ms ease, box-shadow 150ms ease;
}

.select-pill {
  cursor: pointer;
  user-select: none;
}

.select-pill .ts-wrapper,
.select-pill .ts-wrapper .ts-control {
  cursor: pointer;
}

.prop:has(.ts-wrapper.focus),
.prop:has(.ts-wrapper.dropdown-active),
.score-field:has(.ts-wrapper.focus),
.score-field:has(.ts-wrapper.dropdown-active) {
  background: var(--fill-strong);
}

.field-row .ts-wrapper .ts-control > input {
  text-align: right;
}

.field-row .ts-wrapper.input-active .ts-control {
  justify-content: flex-end;
}

.field-row .ts-wrapper .ts-control,
.value-wrap input {
  min-height: 2.25rem;
  padding: 0.25rem 2rem 0.25rem 0.5rem;
  border-radius: var(--radius-control);
  line-height: 1.3;
}

.value-wrap {
  position: relative;
  flex: 1;
  display: flex;
  justify-content: flex-end;
  max-width: 17rem;
}

.value-wrap input {
  width: 100%;
  border: none;
  background: transparent;
  color: var(--ink);
  text-align: right;
  outline: none;
  cursor: pointer;
  transition: background-color 150ms ease;
}

.value-wrap input::placeholder {
  color: var(--ink-soft);
}

.value-wrap::after,
.field-row .ts-wrapper .ts-control::after {
  content: "";
  position: absolute;
  right: 0.875rem;
  top: 50%;
  width: 0.375rem;
  height: 0.375rem;
  border: solid var(--ink-soft);
  border-width: 0 1.5px 1.5px 0;
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

.value-wrap input:focus,
.value-wrap input.-focus- {
  background: var(--fill);
}

.field-row .ts-wrapper .ts-control .item {
  line-height: 1.3;
}

.ts-dropdown .dropdown-input-wrap {
  padding: 0.25rem 0.25rem 0.375rem;
}

.ts-dropdown .dropdown-input {
  width: 100%;
  min-height: 2.25rem;
  padding: 0 0.75rem;
  border: none;
  border-radius: 0.5rem;
  background: var(--fill);
  color: var(--ink);
  font: inherit;
  outline: none;
}

.ts-dropdown .dropdown-input::placeholder {
  color: var(--ink-soft);
}

.flag-high {
  color: #f76b15 !important;
}

.flag-normal {
  color: var(--ink-soft) !important;
}

.flag-low {
  color: #5b9bf0 !important;
}

.ts-dropdown .option .task-flag,
.ts-wrapper .item .task-flag {
  margin-right: 0.375rem;
  font-size: 0.9375rem;
  vertical-align: -0.125rem;
}

.value-wrap .value-btn {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.375rem;
  min-height: 2.25rem;
  max-width: 100%;
  padding: 0.25rem 2rem 0.25rem 0.5rem;
  border-radius: var(--radius-control);
  color: var(--ink);
  text-align: right;
  transition: background-color 150ms ease;
}

.value-wrap .value-btn.empty {
  color: var(--ink-soft);
}

.value-wrap .value-btn .ph {
  color: var(--accent-text);
  font-size: 1rem;
}

.value-wrap .value-btn[aria-expanded="true"],
.value-wrap .value-btn:focus-visible {
  background: var(--fill);
}

.stepper {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.125rem;
  border-radius: var(--radius-pill);
  background: var(--fill);
}

.stepper button {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-pill);
  transition: background-color 150ms ease, transform 120ms var(--ease-out);
}

.stepper button:active {
  transform: scale(0.94);
}

@media (hover: hover) and (pointer: fine) {
  .stepper button:hover {
    background: var(--section);
  }
}

.stepper b {
  min-width: 5.5rem;
  font-weight: 400;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.weekday-pick {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.25rem;
}

.weekday-pick button {
  min-height: 2.25rem;
  border-radius: var(--radius-control);
  background: var(--fill);
  font-size: 0.875rem;
  transition: background-color 150ms ease, color 150ms ease;
}

.weekday-pick button.active {
  background: var(--accent);
  color: var(--on-accent);
}

.ts-dropdown .option,
.ts-dropdown .no-results,
.ts-dropdown .optgroup-header,
.ts-dropdown .create,
.popmenu button,
.ts-dropdown .dropdown-input {
  border-radius: 0.875rem;
}

.custom-scroll,
.custom-scroll * {
  scrollbar-width: none;
}

.custom-scroll ::-webkit-scrollbar,
.custom-scroll::-webkit-scrollbar {
  display: none;
}

@media (hover: none), (pointer: coarse) {
  html,
  body,
  * {
    scrollbar-width: none;
  }

  ::-webkit-scrollbar {
    display: none;
  }
}

.scroll-pill {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1000;
  width: 4px;
  border-radius: var(--radius-pill);
  background: color-mix(in srgb, var(--ink) 25%, transparent);
  box-shadow: 0 0 0 0.5px color-mix(in srgb, var(--ink) 10%, transparent);
  -webkit-backdrop-filter: blur(12px) saturate(1.6);
  backdrop-filter: blur(12px) saturate(1.6);
  opacity: 0;
  pointer-events: none;
  touch-action: none;
  cursor: grab;
  transition: opacity 250ms ease, width 150ms var(--ease-out), background-color 150ms ease;
}

.scroll-pill::before {
  content: "";
  position: absolute;
  inset: 0 -6px;
}

.scroll-pill.visible {
  opacity: 1;
  pointer-events: auto;
}

.scroll-pill:hover,
.scroll-pill.active {
  width: 8px;
  background: color-mix(in srgb, var(--ink) 38%, transparent);
}

.scroll-pill.active {
  cursor: grabbing;
}

@media (prefers-reduced-motion: reduce) {
  .scroll-pill {
    transition: none;
  }
}

.theme-row {
  cursor: default;
}

.theme-row .segmented {
  margin-left: auto;
}

.theme-row .segmented > button {
  display: inline-grid;
  place-items: center;
  padding: 0.25rem 0.5rem;
  font-size: 1rem;
}

.splash {
  position: fixed;
  inset: 0;
  z-index: 900;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 1.125rem;
  background: #0e15ca;
  color: #fff;
}

.splash-native .splash-s {
  animation: none;
}

.splash-hold .splash-dot {
  animation: none;
  opacity: 0;
}

.splash svg {
  width: 4.5rem;
  height: 4.5rem;
  overflow: visible;
  fill: #fff;
}

.splash-s {
  animation: splash-rise 450ms var(--ease-out) both;
}

.splash-dot {
  transform-box: fill-box;
  transform-origin: center;
  animation: splash-drop 700ms 180ms cubic-bezier(0.3, 1.4, 0.5, 1) both;
}

.splash-note {
  font-size: 0.875rem;
  opacity: 0;
}

.splash-update .splash-note,
.splash.update .splash-note {
  opacity: 0.85;
  transition: opacity 300ms 200ms;
}

.splash-update .splash-dot,
.splash.update .splash-dot {
  animation: splash-drop 700ms 180ms cubic-bezier(0.3, 1.4, 0.5, 1) both, splash-pulse 1s 1s ease-in-out infinite;
}

.splash.out {
  opacity: 0;
  visibility: hidden;
  transition: opacity 320ms var(--ease-out), visibility 0s 320ms;
}

@keyframes splash-rise {
  from {
    opacity: 0;
    transform: translateY(0.375rem);
  }
}

@keyframes splash-drop {
  from {
    opacity: 0;
    transform: translateY(-2.875rem);
  }

  30% {
    opacity: 1;
  }
}

@keyframes splash-pulse {
  50% {
    transform: scale(1.45);
    opacity: 0.6;
  }
}

@media (prefers-reduced-motion: reduce) {
  .splash-s,
  .splash-dot,
  .splash-update .splash-dot,
  .splash.update .splash-dot {
    animation: none;
  }
}
