:root {
  --ink: #151821;
  --muted: #697080;
  --line: #dfe3e9;
  --paper: #fff;
  --wash: #fff;
  --soft: #f7f8fa;
  --sidebar: #fafbfc;
  --sidebar-hover: #edf3ff;
  --sidebar-ink: #252a34;
  --accent: #3977ed;
  --accent-soft: #edf3ff;
  --danger: #b93a2f;
  --radius: 9px;
  --shadow: 0 14px 40px rgb(24 33 53 / 10%);
  --motion-fast: 140ms;
  --motion-ui: 210ms;
  --motion-page: 300ms;
  --ease-out: cubic-bezier(0.2, 0.75, 0.25, 1);
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: var(--ink);
  background: var(--wash);
}
.team-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 32px;
}
.team-heading h1 {
  margin: 0 0 8px;
}
.team-heading p,
.team-footnote {
  color: var(--muted);
  margin: 0;
}
.team-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-bottom: 36px;
}
.team-toolbar input {
  width: min(420px, 100%);
  min-width: 0;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 0 14px;
  background: var(--paper);
  color: var(--ink);
}
.team-view-switch {
  display: flex;
  flex-shrink: 0;
  padding: 4px;
  border: 1px solid var(--line);
  background: var(--soft);
  border-radius: 10px;
  gap: 4px;
}
.team-view-switch button {
  min-height: 36px;
  padding: 0 16px;
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: 7px;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.team-view-switch button[aria-pressed="true"] {
  background: var(--accent-soft);
  color: var(--accent);
}
.team-group {
  margin-bottom: 32px;
}
.team-group h2 {
  font-family: Georgia, serif;
  font-weight: 400;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 20px;
  margin: 0 0 20px;
}
.team-group h2 span {
  font-family: inherit;
  font-size: 13px;
  color: var(--muted);
}
.team-group h2::after {
  content: "";
  height: 1px;
  background: var(--line);
  flex: 1;
  margin-left: 4px;
}
.team-people {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
  gap: 18px;
}
.team-person {
  min-width: 0;
  max-width: 380px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  color: var(--ink);
}
.team-portrait {
  position: relative;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--soft);
  color: var(--ink);
  overflow: hidden;
  font-size: 25px;
  margin-bottom: 22px;
}
.team-portrait img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.team-person-name {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 10px;
  min-width: 0;
}
.team-person-name h3 {
  font-family: Georgia, serif;
  font-weight: 400;
  font-size: 22px;
  margin: 0;
  overflow-wrap: anywhere;
}
.team-person-name p {
  flex-basis: 100%;
  color: var(--muted);
  margin: 2px 0 0;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.team-you {
  font-size: 11px;
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 3px 6px;
}
.team-contact {
  margin-top: 24px;
  font-size: 13px;
  overflow-wrap: anywhere;
  color: var(--muted);
}
.team-contact a,
.team-contact a:visited {
  color: var(--muted);
  text-decoration: none;
}
.team-contact a:hover {
  color: var(--accent);
  text-decoration: underline;
}
.team-person-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.team-role {
  font-size: 12px;
  color: var(--muted);
}
html[data-theme="dark"] .team-heading .primary {
  background: var(--accent);
}
.team-footnote {
  border-top: 1px solid var(--line);
  padding-top: 22px;
  margin-top: 40px;
  font-size: 12px;
}
#team-members[data-view="list"] .team-people {
  grid-template-columns: 1fr;
  gap: 10px;
}
#team-members[data-view="list"] .team-person {
  max-width: none;
  display: grid;
  grid-template-columns: 48px minmax(130px, 1fr) minmax(130px, 1fr) auto;
  align-items: center;
  gap: 20px;
  padding: 18px;
}
#team-members[data-view="list"] .team-portrait {
  width: 48px;
  height: 48px;
  font-size: 18px;
  margin: 0;
}
#team-members[data-view="list"] .team-person-name h3 {
  font-size: 17px;
}
#team-members[data-view="list"] .team-contact,
#team-members[data-view="list"] .team-person-footer {
  margin: 0;
  padding: 0;
  border: 0;
}
@media (max-width: 720px) {
  .team-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }
  .team-toolbar {
    flex-wrap: wrap;
    margin-bottom: 26px;
  }
  .team-toolbar input {
    width: 100%;
  }
  .team-person {
    max-width: none;
  }
  #team-members[data-view="list"] .team-person {
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 12px;
  }
  #team-members[data-view="list"] .team-contact,
  #team-members[data-view="list"] .team-person-footer {
    grid-column: 2;
  }
}
html[data-theme="dark"] {
  color-scheme: dark;
  --ink: #f7f8fa;
  --muted: #aeb7c1;
  --line: #303943;
  --paper: #1b2127;
  --wash: #0f1317;
  --soft: #222a31;
  --sidebar: #14191e;
  --sidebar-hover: #202a36;
  --sidebar-ink: #e9edf1;
  --accent: #8eb4ff;
  --accent-soft: #202d42;
  --danger: #ff968d;
  --shadow: 0 20px 55px rgb(0 0 0 / 42%);
}
html[data-theme="dark"] .panel,
html[data-theme="dark"] .card,
html[data-theme="dark"] .metric,
html[data-theme="dark"] .table-panel,
html[data-theme="dark"] .toolbar,
html[data-theme="dark"] .secondary,
html[data-theme="dark"] .social,
html[data-theme="dark"] .dialog,
html[data-theme="dark"] .command,
html[data-theme="dark"] .setup-panel,
html[data-theme="dark"] .getting-started,
html[data-theme="dark"] .setup-checklist,
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea {
  background: var(--paper);
  color: var(--ink);
  border-color: var(--line);
}
html[data-theme="dark"] .attention-row:hover,
html[data-theme="dark"] .list-row:hover {
  background: #20272d;
}
html[data-theme="dark"] .primary {
  color: #0d1728;
  box-shadow: 0 7px 20px rgb(35 79 159 / 28%);
}
html[data-theme="dark"] .sidebar {
  box-shadow: 12px 0 40px rgb(0 0 0 / 10%);
}
html[data-theme="dark"] .company-switch,
html[data-theme="dark"] .profile-button {
  background: #181e23;
}
html[data-theme="dark"] .metric-grid {
  background: var(--line);
}
html[data-theme="dark"] .metric:hover {
  background: #1d252e;
}
html[data-theme="dark"] .panel:hover,
html[data-theme="dark"] .card:hover {
  border-color: #3b4c61;
  box-shadow: 0 16px 40px rgb(0 0 0 / 20%);
}
html[data-theme="dark"] .chart {
  background-image: repeating-linear-gradient(
    to top,
    transparent 0,
    transparent 49px,
    rgb(255 255 255 / 4%) 50px
  );
}
html[data-theme="dark"] .bar {
  background: #7fa8f8;
  box-shadow: 0 -5px 18px rgb(84 132 224 / 18%);
}
html[data-theme="dark"] .status {
  background: #20262c;
  border-color: #37414a;
  color: #c9d0d7;
}
html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder {
  color: #747e88;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-height: 100vh;
  background: var(--wash);
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a {
  touch-action: manipulation;
}
.wordmark {
  font-family: Georgia, serif;
  font-size: 25px;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -1px;
}
.wordmark b {
  font-family: inherit;
}
.wordmark i {
  font-weight: 400;
}
.wordmark-light {
  color: var(--sidebar-ink);
  margin: 24px;
}
.app {
  min-height: 100vh;
}
.app.no-company {
  grid-template-columns: minmax(0, 1fr);
}
.app.no-company .sidebar,
.app.no-company .mobile-head {
  display: none;
}
.app.no-company .content {
  grid-column: 1;
  width: min(1100px, calc(100% - 48px));
  margin-inline: auto;
}
.onboarding-profile-button {
  width: min(320px, 100%);
  margin: 28px auto 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  transition:
    border-color var(--motion-ui) ease,
    transform var(--motion-ui) var(--ease-out);
}
.onboarding-profile-button:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}
.onboarding-profile-button > span:nth-child(2) {
  display: grid;
  gap: 3px;
  flex: 1;
}
.onboarding-profile-button small {
  color: var(--muted);
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 244px;
  display: flex;
  flex-direction: column;
  background: var(--sidebar);
  color: var(--sidebar-ink);
  border-right: 1px solid var(--line);
}
.company-switch,
.profile-button {
  margin: 10px 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  color: var(--sidebar-ink);
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-align: left;
}
.company-switch span:first-child,
.profile-button span:nth-child(2) {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.sidebar small {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.1em;
}
.sidebar nav {
  padding: 10px 8px;
  overflow: auto;
  flex: 1;
}
.sidebar nav small {
  display: block;
  padding: 17px 13px 7px;
}
.sidebar nav a {
  display: block;
  color: var(--sidebar-ink);
  padding: 9px 12px;
  border-radius: 6px;
  text-decoration: none;
  font-size: 14px;
}
.sidebar nav a:hover,
.sidebar nav a.active {
  background: var(--sidebar-hover);
  color: var(--accent);
}
.sidebar-footer {
  margin-top: auto;
  padding: 0 6px 14px;
}
.profile-button {
  width: calc(100% - 32px);
}
.avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 18%, var(--line));
  color: var(--ink);
  display: grid;
  place-items: center;
  font-weight: 700;
}
.content {
  margin-left: 244px;
  min-height: 100vh;
  padding: 42px 46px 80px;
  max-width: 1560px;
}
.content:focus {
  outline: none;
}
.page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}
.page-head h1 {
  font:
    400 42px/1.08 Georgia,
    serif;
  margin: 0;
  letter-spacing: -1.5px;
}
.page-head h1 i {
  font-weight: 400;
}
.eyebrow {
  font-size: 11px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 8px;
}
.muted {
  color: var(--muted);
}
.primary,
.secondary,
.social,
.link-button {
  border: 0;
  border-radius: 7px;
  padding: 11px 16px;
  cursor: pointer;
  transition:
    transform var(--motion-fast) ease,
    box-shadow var(--motion-fast) ease,
    border-color var(--motion-fast) ease,
    background-color var(--motion-fast) ease;
}
.primary:hover,
.secondary:hover,
.social:hover {
  transform: translateY(-1px);
}
.primary:active,
.secondary:active,
.social:active {
  transform: translateY(0) scale(0.985);
}
.primary {
  background: var(--accent);
  color: #fff;
  font-weight: 650;
  text-decoration: none;
}
.secondary,
.social {
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--ink);
}
.link-button {
  background: transparent;
  color: var(--accent);
}
.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
.metric {
  background: var(--paper);
  padding: 22px;
  transition:
    background-color var(--motion-fast) ease,
    transform var(--motion-fast) ease;
}
.metric:hover {
  background: color-mix(in srgb, var(--accent) 4%, var(--paper));
  transform: translateY(-2px);
}
.metric small {
  display: block;
  color: var(--muted);
  margin-bottom: 18px;
}
.metric strong {
  font:
    400 28px Georgia,
    serif;
}
.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(320px, 1fr);
  gap: 18px;
  margin-top: 18px;
}
.onboarding-choice {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.onboarding-choice .panel {
  padding: 42px;
  text-align: left;
}
.setup-panel {
  max-width: 920px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.setup-panel section {
  padding: 28px;
  border-bottom: 1px solid var(--line);
}
.setup-panel footer {
  padding: 22px 28px;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}
.setup-title {
  max-width: 980px;
  margin: 0 auto 28px;
  position: relative;
}
.setup-title h1 {
  margin: 0 0 8px;
  font:
    400 clamp(36px, 5vw, 58px)/1.05 Georgia,
    serif;
}
.setup-title p {
  color: var(--muted);
  margin: 0;
}
.setup-title > a {
  position: absolute;
  right: 0;
  top: 4px;
  color: var(--muted);
  font-size: 26px;
  text-decoration: none;
}
.setup-wizard {
  max-width: 980px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  min-height: 570px;
  background: var(--paper);
  border: 1px solid var(--line);
  box-shadow: 0 24px 70px rgb(18 24 28 / 8%);
}
.setup-wizard > nav {
  padding: 34px 22px;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.setup-wizard > nav button {
  border: 0;
  background: transparent;
  color: var(--muted);
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 10px;
  text-align: left;
}
.setup-wizard > nav button b {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
}
.setup-wizard > nav button.active {
  color: var(--ink);
}
.setup-wizard > nav button.active b {
  color: white;
  background: var(--accent);
  border-color: var(--accent);
}
.setup-stage {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.setup-stage > section {
  padding: 44px 48px;
  flex: 1;
}
.setup-stage h2 {
  margin: 0 0 8px;
  font:
    400 31px Georgia,
    serif;
}
.setup-stage > footer {
  padding: 20px 48px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}
.setup-stage > footer [data-cancel-setup] {
  margin-right: auto;
}
.tax-choices {
  display: grid;
  gap: 10px;
  margin: 28px 0 18px;
}
.tax-choice {
  position: relative;
}
.tax-choice input {
  position: absolute;
  opacity: 0;
}
.tax-choice span {
  display: block;
  padding: 17px 18px 17px 46px;
  border: 1px solid var(--line);
  position: relative;
  cursor: pointer;
}
.tax-choice span::before {
  content: "";
  position: absolute;
  left: 17px;
  top: 19px;
  width: 15px;
  height: 15px;
  border: 1px solid var(--muted);
  border-radius: 50%;
}
.tax-choice input:checked + span {
  border-color: var(--accent);
}
.tax-choice input:checked + span::before {
  border: 5px solid var(--accent);
}
.tax-choice strong,
.tax-choice small {
  display: block;
}
.tax-choice small {
  margin-top: 4px;
  color: var(--muted);
}
.tax-help {
  padding: 16px 18px;
  background: color-mix(in srgb, var(--accent) 8%, var(--paper));
}
.tax-help summary {
  cursor: pointer;
  font-weight: 700;
}
.tax-help p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.55;
}
.getting-started {
  padding: 30px 32px 20px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.getting-started h2 {
  margin: 0 0 8px;
  font:
    400 30px Georgia,
    serif;
}
.getting-started > p {
  margin: 0 0 20px;
  color: var(--muted);
}
.dashboard-welcome {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 28px;
  margin-bottom: 32px;
}
.dashboard-welcome p {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 15px;
}
.dashboard-welcome h1 {
  margin: 0;
  font:
    400 clamp(38px, 4.2vw, 58px) / 1.03 Georgia,
    serif;
  letter-spacing: -2.5px;
}
.dashboard-welcome h1 i {
  font-weight: 400;
}
.first-run-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(330px, 0.9fr);
  gap: 22px;
  align-items: start;
}
.first-run-main {
  display: grid;
  gap: 22px;
}
.start-list {
  border-top: 1px solid var(--line);
}
.start-list a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 18px 0;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.start-list a:last-child {
  border-bottom: 0;
}
.start-list a > span {
  display: grid;
  gap: 4px;
}
.start-list small,
.setup-step small {
  color: var(--muted);
  line-height: 1.45;
}
.start-list a > b {
  flex: 0 0 auto;
  padding: 9px 13px;
  border: 1px solid var(--line);
  border-radius: 7px;
  font-size: 13px;
  font-weight: 600;
}
.start-list a:hover > b {
  border-color: var(--accent);
  color: var(--accent);
}
.setup-checklist {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.setup-checklist-head {
  padding: 27px 26px 22px;
}
.setup-checklist-head h2 {
  margin: 0 0 8px;
  font:
    400 25px Georgia,
    serif;
}
.setup-checklist-head p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
}
.setup-progress {
  display: block;
  height: 4px;
  background: var(--soft);
  border-radius: 3px;
  overflow: hidden;
}
.setup-progress i {
  display: block;
  height: 100%;
  background: var(--accent);
  transition: width 0.25s ease;
}
.setup-step {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 13px;
  align-items: center;
  padding: 16px 22px;
  border-top: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}
.setup-step:hover {
  background: var(--soft);
}
.setup-step > span:nth-child(2) {
  display: grid;
  gap: 3px;
}
.setup-check {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid #bdc4ce;
  border-radius: 50%;
  color: white;
  font-size: 12px;
}
.setup-step.done .setup-check {
  background: var(--accent);
  border-color: var(--accent);
}
.first-activity .empty {
  min-height: 180px;
  display: grid;
  place-content: center;
}
.start-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}
.choice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.choice {
  position: relative;
}
.choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.choice span {
  display: block;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  cursor: pointer;
}
.choice input:checked + span {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}
.choice input:focus-visible + span {
  outline: 3px solid color-mix(in srgb, var(--accent) 35%, transparent);
  outline-offset: 2px;
}
.panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  transition:
    transform var(--motion-ui) var(--ease-out),
    box-shadow var(--motion-ui) ease,
    border-color var(--motion-ui) ease;
}
.panel:hover {
  border-color: color-mix(in srgb, var(--accent) 22%, var(--line));
  box-shadow: 0 12px 34px rgb(24 33 53 / 7%);
}
.panel-head {
  padding: 19px 22px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.panel h2 {
  font:
    400 21px Georgia,
    serif;
  margin: 0;
}
.attention-row,
.activity-row,
.list-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 18px;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
}
.attention-row:last-child,
.activity-row:last-child,
.list-row:last-child {
  border: 0;
}
.attention-row:hover,
.list-row:hover {
  background: var(--soft);
}
.attention-row {
  transition:
    background-color var(--motion-fast) ease,
    padding-left var(--motion-fast) ease;
}
.attention-row:hover {
  padding-left: 24px;
}
.row-main {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.row-main small {
  color: var(--muted);
}
.amount {
  font-family: Georgia, serif;
}
.danger {
  color: var(--danger);
}
.chart {
  height: 250px;
  padding: 22px;
  display: flex;
  justify-content: flex-start;
  gap: 12px;
  align-items: flex-end;
}
.bar-wrap {
  flex: 0 1 54px;
  min-width: 18px;
  max-width: 54px;
  height: 100%;
  display: flex;
  gap: 3px;
  align-items: flex-end;
  border-bottom: 1px solid var(--line);
}
.bar {
  flex: 1;
  min-height: 2px;
  background: var(--accent);
  border-radius: 2px 2px 0 0;
  transform-origin: bottom;
  animation: chart-rise 520ms var(--ease-out) both;
}
.bar.paid {
  background: #9aa5b8;
}
.chart-label {
  font-size: 10px;
  color: var(--muted);
  writing-mode: vertical-rl;
}
.empty {
  padding: 45px 22px;
  text-align: center;
  color: var(--muted);
}
.empty h3 {
  font:
    400 23px Georgia,
    serif;
  color: var(--ink);
  margin: 0 0 8px;
}
.table-panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
.toolbar {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}
.toolbar input,
.field input,
.field select,
.field textarea,
label input,
label select,
label textarea {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--paper);
}
.row-main,
.row-main:visited {
  color: var(--ink);
  text-decoration-color: color-mix(in srgb, var(--accent) 55%, transparent);
}
.panel-head a,
.panel-head a:visited {
  color: var(--accent);
}
.status {
  font-size: 12px;
  border: 1px solid var(--line);
  padding: 5px 8px;
  border-radius: 20px;
  text-transform: capitalize;
}
.status.overdue {
  color: var(--danger);
  border-color: #e8b2ad;
}
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
}
.settings-layout {
  display: grid;
  grid-template-columns: repeat(3, minmax(260px, 1fr));
  gap: 18px;
  align-items: stretch;
}
.company-settings-shell {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 34px;
  align-items: start;
}
.settings-nav {
  position: sticky;
  top: 28px;
  display: grid;
  border-left: 1px solid var(--line);
}
.settings-nav a {
  color: var(--muted);
  text-decoration: none;
  padding: 11px 16px;
  border-left: 2px solid transparent;
  margin-left: -1px;
}
.settings-nav a:hover,
.settings-nav a:focus-visible,
.settings-nav a.active {
  color: var(--ink);
  border-left-color: var(--accent);
}
.company-settings-shell .settings-layout {
  grid-template-columns: 1fr;
}
.company-settings-shell .features-card {
  grid-column: auto;
}
.settings-card {
  min-width: 0;
  padding: 25px;
}
.settings-card h3 {
  font-size: 16px;
  margin-bottom: 18px;
}
.settings-card > small {
  display: block;
  margin-top: 12px;
}
.company-logo-setting {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.company-logo-setting h4 {
  margin: 0 0 12px;
}
.company-logo-setting img,
.company-logo-setting .logo-placeholder {
  width: 100%;
  height: 92px;
  object-fit: contain;
  background: var(--canvas);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  color: var(--muted);
  margin-bottom: 12px;
}
.company-logo-setting small {
  display: block;
  margin-top: 10px;
}
.settings-summary {
  display: grid;
  gap: 10px;
  margin: 0 0 20px;
}
.settings-summary > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
.settings-summary dt {
  color: var(--muted);
}
.settings-summary dd {
  margin: 0;
  text-align: right;
}
.features-card {
  grid-column: 1 / -1;
}
.settings-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 20px;
}
.settings-section-head h3,
.settings-section-head p {
  margin: 0;
}
.settings-section-head p {
  color: var(--muted);
  margin-top: 6px;
}
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}
.feature-choice {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  padding: 14px 16px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.feature-choice:nth-child(3n) {
  border-right: 0;
}
.feature-choice:nth-last-child(-n + 3) {
  border-bottom: 0;
}
.feature-choice span {
  overflow-wrap: normal;
  word-break: normal;
}
.feature-choice input {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  accent-color: var(--accent);
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 20px;
}
.card h3 {
  margin: 0 0 7px;
}
.card p {
  color: var(--muted);
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
}
.field.full {
  grid-column: 1/-1;
}
.auth-view {
  min-height: 100vh;
  overflow: hidden;
  background:
    radial-gradient(
      circle at 17% 22%,
      rgb(57 119 237 / 12%),
      transparent 28rem
    ),
    linear-gradient(135deg, #f8f9fb 0%, #eef2f7 100%);
  color: var(--ink);
  padding: 26px clamp(24px, 4vw, 68px) 38px;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 18px;
}
.auth-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  position: relative;
  z-index: 3;
}
.auth-layout {
  width: min(1380px, 100%);
  min-height: 0;
  margin: auto;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(390px, 0.75fr);
  align-items: center;
  gap: clamp(32px, 7vw, 108px);
}
.auth-brand {
  position: relative;
  min-height: min(690px, calc(100vh - 120px));
  display: flex;
  align-items: flex-end;
  padding: 54px clamp(20px, 4vw, 58px);
  overflow: hidden;
  background: #0b0f13;
  border: 1px solid rgb(15 25 38 / 10%);
  border-radius: 26px;
  box-shadow: 0 30px 80px rgb(25 40 65 / 16%);
  isolation: isolate;
}
.auth-brand:after {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 38% 0 0;
  background: linear-gradient(to bottom, transparent, rgb(6 10 15 / 82%) 74%);
  pointer-events: none;
}
.auth-art {
  position: absolute;
  z-index: -1;
  inset: -8% -5% 7% -8%;
  display: grid;
  place-items: center;
  pointer-events: none;
}
.auth-art:after {
  content: "";
  position: absolute;
  inset: 20% 8% 10%;
  background: radial-gradient(ellipse, rgb(74 124 222 / 21%), transparent 68%);
  filter: blur(36px);
}
.auth-art img {
  position: relative;
  z-index: 1;
  width: min(820px, 112%);
  height: auto;
  object-fit: contain;
  filter: saturate(1.08) contrast(1.08)
    drop-shadow(0 34px 42px rgb(0 0 0 / 32%));
  animation: auth-float 9s ease-in-out infinite;
}
.auth-orbit {
  position: absolute;
  width: min(560px, 72%);
  aspect-ratio: 1;
  border: 1px solid rgb(57 119 237 / 16%);
  border-radius: 50%;
  transform: rotate(-18deg) scaleY(0.48);
}
.auth-brand-copy {
  max-width: 560px;
  position: relative;
  z-index: 2;
  color: #f7f8fa;
  text-shadow: 0 2px 22px rgb(0 0 0 / 72%);
}
.auth-brand-copy p {
  margin: 0 0 16px;
  color: #c4ccd6;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}
.auth-brand-copy p span {
  padding: 0 5px;
  color: var(--accent);
}
.auth-brand-copy h2 {
  margin: 0;
  font:
    400 clamp(44px, 5vw, 76px)/0.96 Georgia,
    serif;
  letter-spacing: -0.055em;
}
.auth-brand-copy h2 i {
  font-weight: 400;
}
.auth-brand-copy small {
  display: block;
  max-width: 500px;
  margin-top: 20px;
  color: #c4ccd6;
  font-size: 15px;
  line-height: 1.65;
}
.auth-card {
  width: min(480px, 100%);
  margin: auto 0;
  background: rgb(255 255 255 / 82%);
  color: var(--ink);
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid rgb(255 255 255 / 88%);
  border-radius: 22px;
  box-shadow: 0 34px 90px rgb(25 40 65 / 15%);
  backdrop-filter: blur(24px);
  animation: auth-card-in 650ms cubic-bezier(0.22, 1, 0.36, 1) both;
}
.auth-home {
  display: inline-block;
  margin-bottom: 34px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
  text-decoration: none;
}
.auth-home:hover {
  color: var(--ink);
}
.auth-card h1 {
  font:
    400 clamp(36px, 4vw, 52px)/1 Georgia,
    serif;
  letter-spacing: -0.045em;
  margin: 0 0 14px;
}
.auth-card > .muted {
  margin: 0;
  line-height: 1.55;
}
.auth-card label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin: 14px 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}
.auth-card input {
  min-height: 48px;
  padding: 11px 13px;
  background: rgb(255 255 255 / 72%);
  border-color: #d8dee7;
  border-radius: 9px;
  color: var(--ink);
  font-size: 15px;
}
.auth-card input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgb(57 119 237 / 12%);
  outline: none;
}
.auth-card .primary {
  width: 100%;
  min-height: 50px;
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-inline: 18px;
  border-radius: 9px;
  box-shadow: 0 12px 28px rgb(57 119 237 / 22%);
}
.social-row {
  display: block;
  margin: 24px 0 18px;
}
.auth-card .social {
  width: 100%;
  min-height: 48px;
  background: rgb(255 255 255 / 74%);
  border-radius: 9px;
  font-weight: 650;
}
.or {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
}
.or:before,
.or:after {
  content: "";
  height: 1px;
  background: var(--line);
  flex: 1;
}
.auth-links {
  margin: 18px 0 20px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
}
.auth-links .link-button {
  padding: 3px 0;
  color: var(--muted);
  background: transparent;
  font-size: 12px;
}
.auth-links .link-button:hover {
  color: var(--accent);
}
.legal-note {
  margin: 0;
  font-size: 11px;
  color: var(--muted);
  line-height: 1.5;
}
.legal-note a {
  color: inherit;
}
html[data-theme="dark"] .auth-view {
  background:
    radial-gradient(
      circle at 18% 20%,
      rgb(90 133 218 / 14%),
      transparent 31rem
    ),
    #0b0f13;
}
html[data-theme="dark"] .auth-card {
  background: rgb(24 30 36 / 82%);
  border-color: rgb(255 255 255 / 9%);
  box-shadow: 0 38px 100px rgb(0 0 0 / 42%);
}
html[data-theme="dark"] .auth-card input,
html[data-theme="dark"] .auth-card .social {
  background: rgb(255 255 255 / 4%);
}
html[data-theme="dark"] .auth-brand-copy {
  text-shadow: 0 1px 22px #0b0f13;
}
html[data-theme="dark"] .auth-brand {
  border-color: rgb(255 255 255 / 8%);
  box-shadow: 0 38px 100px rgb(0 0 0 / 30%);
}
html[data-theme="dark"] .auth-brand-copy p,
html[data-theme="dark"] .auth-brand-copy small {
  color: #a7b0bb;
}
html[data-theme="dark"] .auth-art img {
  filter: drop-shadow(0 38px 48px rgb(0 0 0 / 46%));
}
@keyframes auth-float {
  0%,
  100% {
    transform: translate3d(0, -5px, 0) rotate(-1deg);
  }
  50% {
    transform: translate3d(0, 9px, 0) rotate(1deg);
  }
}
@keyframes auth-card-in {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.toast-stack {
  position: fixed;
  z-index: 100;
  top: max(16px, env(safe-area-inset-top));
  right: 20px;
  display: grid;
  width: min(390px, calc(100vw - 32px));
  gap: 9px;
  pointer-events: none;
}
.toast-message {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  overflow: hidden;
  padding: 14px 12px 14px 16px;
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 11px;
  box-shadow: var(--shadow);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  pointer-events: auto;
  animation: toast-enter var(--motion-ui) var(--ease-out) both;
}
.toast-message.timing::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 2px;
  background: var(--accent);
  transform-origin: left;
  animation: toast-life 7s linear both;
}
.toast-message.error {
  border-color: color-mix(in srgb, var(--danger) 45%, var(--line));
}
.toast-message.error::after {
  background: var(--danger);
}
.toast-message button {
  width: 30px;
  height: 30px;
  padding: 0;
  background: var(--soft);
  color: var(--muted);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
}
.toast-message.leaving {
  animation: toast-leave 220ms ease both;
}
dialog {
  background: var(--paper);
  color: var(--ink);
  border: 0;
  border-radius: 16px;
  padding: 0;
  box-shadow: 0 28px 90px rgb(5 12 22 / 28%);
  width: min(600px, calc(100% - 24px));
}
dialog.wide {
  width: min(840px, calc(100% - 24px));
  max-height: min(900px, calc(100vh - 32px));
}
dialog.wide .dialog {
  max-height: inherit;
  display: flex;
  flex-direction: column;
}
dialog.wide #modal-body {
  overflow: auto;
}
.quote-items {
  display: grid;
  grid-column: 1 / -1;
  width: auto;
  gap: 12px;
}
.quote-items-head,
.quote-item-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.quote-items-head h3,
.quote-items-head p {
  margin: 0;
}
.quote-items-head p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}
.quote-item {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
}
.quote-item-title {
  grid-column: 1 / -1;
}
.quote-item-title strong {
  font-size: 13px;
}
dialog[open] {
  animation: dialog-enter var(--motion-ui) var(--ease-out) both;
}
dialog::backdrop {
  background: rgb(16 20 23 / 58%);
  backdrop-filter: blur(5px) saturate(0.8);
  animation: backdrop-enter var(--motion-ui) ease both;
}
.dialog {
  background: var(--paper);
  color: var(--ink);
  padding: 0;
  margin: 0;
}
.dialog > header,
.dialog > footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 26px;
  border-bottom: 1px solid var(--line);
}
.dialog > footer {
  border: 0;
  border-top: 1px solid var(--line);
  justify-content: flex-end;
  gap: 8px;
}
.dialog > header h2 {
  margin: 0;
  font:
    400 28px Georgia,
    serif;
  letter-spacing: -0.5px;
}
.dialog > header button {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--soft);
  color: var(--ink);
  font-size: 26px;
  cursor: pointer;
  transition:
    transform var(--motion-fast) ease,
    background-color var(--motion-fast) ease;
}
.dialog > header button:hover {
  transform: rotate(4deg) scale(1.04);
  background: var(--accent-soft);
}
.dialog.compact {
  padding-bottom: 16px;
}
.dialog.compact > button {
  margin: 10px 16px;
}
.full {
  width: calc(100% - 32px);
}
#modal-body {
  padding: 26px;
  background: color-mix(in srgb, var(--accent) 2.5%, var(--paper));
}

#modal-body .form-grid {
  gap: 18px;
}

#modal-body .field span,
#modal-body label > span {
  display: block;
  margin-bottom: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
}

#modal-body input,
#modal-body select,
#modal-body textarea {
  min-height: 46px;
  padding: 12px 13px;
  border-color: color-mix(in srgb, var(--ink) 18%, transparent);
  border-radius: 9px;
  background: var(--paper);
  transition:
    border-color var(--motion-fast) ease,
    box-shadow var(--motion-fast) ease,
    transform var(--motion-fast) ease;
}

#modal-body input:hover,
#modal-body select:hover,
#modal-body textarea:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
}

#modal-body input:focus,
#modal-body select:focus,
#modal-body textarea:focus {
  outline: 0;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 15%, transparent);
}

@keyframes dialog-enter {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

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

@keyframes toast-enter {
  from {
    opacity: 0;
    transform: translateY(-10px) scale(0.98);
  }
}

@keyframes toast-leave {
  to {
    opacity: 0;
    transform: translateY(-8px) scale(0.98);
  }
}

@keyframes toast-life {
  to {
    transform: scaleX(0);
  }
}

@keyframes chart-rise {
  from {
    opacity: 0;
    transform: scaleY(0.08);
  }
  to {
    opacity: 1;
    transform: scaleY(1);
  }
}

@keyframes dashboard-enter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.dashboard-welcome,
.metric-grid,
.dashboard-grid,
.content > .panel,
.first-run-grid {
  animation: dashboard-enter var(--motion-page) var(--ease-out) both;
}
.metric-grid,
.first-run-grid {
  animation-delay: 50ms;
}
.dashboard-grid {
  animation-delay: 90ms;
}
.content > .panel {
  animation-delay: 130ms;
}
.company-option {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  padding: 16px 22px;
  text-align: left;
  display: flex;
  justify-content: space-between;
}
.company-option:hover {
  background: var(--soft);
}
.command {
  margin: 0;
  overflow: hidden;
  background: var(--paper);
}
.command label {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 17px 20px;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}
.command input {
  border: 0;
  outline: 0;
  padding: 0;
  background: transparent !important;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.5;
  width: 100%;
}
#command-results {
  max-height: min(440px, 55vh);
  padding: 8px;
  overflow-y: auto;
  background: var(--paper);
}
.command button {
  display: grid;
  gap: 3px;
  width: 100%;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  padding: 13px 14px;
  text-align: left;
  cursor: pointer;
  transition:
    color var(--motion-fast) ease,
    background-color var(--motion-fast) ease;
}
.command button:hover,
.command button:focus-visible {
  outline: 0;
  background: var(--accent-soft);
  color: var(--accent);
}
.command button strong {
  font-size: 14px;
  font-weight: 650;
}
.command button small {
  padding: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}
.command > small {
  display: block;
  padding: 11px 20px 13px;
  border-top: 1px solid var(--line);
  background: var(--soft);
  color: var(--muted);
  font-size: 11px;
}
.mobile-head {
  display: none;
}
.settings-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.settings-tabs button {
  border: 1px solid var(--line);
  background: #fff;
  padding: 8px 11px;
  border-radius: 7px;
}
.theme-switcher {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 3px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}
.sidebar .theme-switcher {
  margin: 2px 10px 0;
}
.theme-switcher button {
  border: 0;
  border-radius: 5px;
  padding: 7px 8px;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  cursor: pointer;
}
.theme-switcher button:hover {
  color: var(--ink);
}
.theme-switcher button.selected {
  background: var(--paper);
  color: var(--accent);
  box-shadow: 0 1px 4px rgb(20 28 45 / 12%);
}
.progress {
  display: none;
}
@media (max-width: 1050px) {
  .metric-grid {
    grid-template-columns: 1fr 1fr;
  }
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .cards {
    grid-template-columns: 1fr 1fr;
  }
  .first-run-grid {
    grid-template-columns: 1fr;
  }
  .settings-layout {
    grid-template-columns: 1fr 1fr;
  }
  .settings-card:last-child {
    grid-column: 1 / -1;
  }
}
@media (max-width: 760px) {
  .company-settings-shell {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .settings-nav {
    position: static;
    grid-auto-flow: column;
    overflow-x: auto;
    border-left: 0;
    border-bottom: 1px solid var(--line);
  }
  .settings-nav a {
    white-space: nowrap;
    border-left: 0;
    border-bottom: 2px solid transparent;
  }
  .settings-nav a.active {
    border-left-color: transparent;
    border-bottom-color: var(--accent);
  }
  .setup-wizard {
    grid-template-columns: 1fr;
  }
  .setup-wizard > nav {
    flex-direction: row;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 14px;
  }
  .setup-wizard > nav button {
    flex: 1;
    justify-content: center;
  }
  .setup-stage > section {
    padding: 28px 20px;
  }
  .setup-stage > footer {
    padding: 16px 20px;
  }
  .onboarding-choice,
  .choice-grid {
    grid-template-columns: 1fr;
  }
  .sidebar {
    transform: translateX(-100%);
    transition: 0.2s;
    z-index: 20;
  }
  .sidebar.open {
    transform: none;
  }
  .mobile-head {
    height: 58px;
    background: var(--paper);
    color: var(--ink);
    border-bottom: 1px solid var(--line);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 15px;
    position: sticky;
    top: 0;
    z-index: 10;
  }
  .mobile-head button {
    border: 0;
    background: none;
    color: var(--ink);
    font-size: 22px;
  }
  .mobile-head .wordmark {
    color: var(--ink);
    font-size: 21px;
  }
  .content {
    margin: 0;
    padding: 25px 16px 90px;
  }
  .page-head {
    align-items: flex-start;
    flex-direction: column;
  }
  .page-head h1 {
    font-size: 32px;
  }
  .metric-grid {
    grid-template-columns: 1fr 1fr;
  }
  .metric {
    padding: 16px;
  }
  .metric strong {
    font-size: 22px;
  }
  .metric small {
    margin-bottom: 12px;
  }
  .cards {
    grid-template-columns: 1fr;
  }
  .dashboard-welcome {
    flex-direction: column;
    margin-bottom: 24px;
  }
  .dashboard-welcome h1 {
    font-size: 40px;
    letter-spacing: -1.8px;
  }
  .getting-started {
    padding: 24px 20px 12px;
  }
  .start-list a {
    align-items: flex-start;
  }
  .start-list a > b {
    display: none;
  }
  .settings-layout {
    grid-template-columns: 1fr;
  }
  .features-card,
  .settings-card:last-child {
    grid-column: auto;
  }
  .settings-section-head {
    align-items: stretch;
    flex-direction: column;
  }
  .feature-grid {
    grid-template-columns: 1fr;
  }
  .feature-choice,
  .feature-choice:nth-child(3n),
  .feature-choice:nth-last-child(-n + 3) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .feature-choice:last-child {
    border-bottom: 0;
  }
  .list-row,
  .attention-row,
  .activity-row {
    grid-template-columns: 1fr auto;
  }
  .list-row > *:nth-child(3),
  .activity-row > *:nth-child(3) {
    grid-column: 1/-1;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .quote-item {
    grid-template-columns: 1fr;
  }
  .field.full {
    grid-column: auto;
  }
  .toolbar {
    flex-direction: column;
  }
  .auth-view {
    min-height: 100svh;
    overflow: auto;
    padding: 18px;
    gap: 14px;
  }
  .auth-header {
    align-items: center;
  }
  .auth-header .theme-switcher {
    max-width: 174px;
  }
  .auth-layout {
    display: block;
  }
  .auth-brand {
    min-height: 210px;
    padding: 24px 6px 16px;
    align-items: flex-end;
    border-radius: 18px;
  }
  .auth-art {
    inset: -55% -18% -12% 5%;
    opacity: 0.48;
  }
  .auth-art img {
    width: 480px;
  }
  .auth-orbit {
    display: none;
  }
  .auth-brand-copy p {
    display: none;
  }
  .auth-brand-copy h2 {
    font-size: clamp(37px, 11vw, 48px);
  }
  .auth-brand-copy small {
    display: none;
  }
  .auth-card {
    padding: 26px 22px;
    border-radius: 18px;
  }
  .auth-home {
    margin-bottom: 24px;
  }
  .auth-card h1 {
    font-size: 38px;
  }
  .social-row {
    margin-top: 20px;
  }
  .auth-links {
    flex-wrap: wrap;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
html[data-reduced-motion="true"] *,
html[data-reduced-motion="true"] *:before,
html[data-reduced-motion="true"] *:after {
  scroll-behavior: auto !important;
  transition: none !important;
  animation: none !important;
}
.motion-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
}
.motion-toggle input {
  position: absolute;
  inset: 50% auto auto 20px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.motion-toggle > span {
  width: 42px;
  height: 24px;
  padding: 3px;
  border-radius: 99px;
  background: var(--line);
  transition: background-color var(--motion-fast) ease;
}
.motion-toggle > span::after {
  content: "";
  display: block;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--paper);
  box-shadow: 0 1px 4px rgb(12 18 28 / 20%);
  transition: transform var(--motion-fast) var(--ease-out);
}
.motion-toggle input:checked + span {
  background: var(--accent);
}
.motion-toggle input:checked + span::after {
  transform: translateX(18px);
}
.motion-toggle input:focus-visible + span {
  outline: 3px solid color-mix(in srgb, var(--accent) 25%, transparent);
  outline-offset: 2px;
}
.motion-toggle b {
  min-width: 23px;
  font-size: 12px;
}
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}
.settings-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  display: grid;
  place-items: center;
  background: #eef0f1;
  font:
    600 24px Georgia,
    serif;
  margin: 14px 0;
}
.file-button {
  display: inline-block;
  margin: 5px 8px 8px 0;
}
.visually-hidden {
  position: fixed !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
.company-logo-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
}
.company-logo-setting button:disabled {
  cursor: wait;
  opacity: 0.65;
}
.quiet {
  border: 0;
  background: transparent;
  color: var(--accent);
  padding: 9px;
  cursor: pointer;
}
.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.setting-row span {
  overflow-wrap: anywhere;
}
.setting-row small,
.card small {
  display: block;
  color: var(--muted);
  margin-top: 5px;
  line-height: 1.45;
}

/* Settings workspace */
.settings-workspace {
  --settings-accent: var(--accent);
  --settings-tint: color-mix(in srgb, var(--settings-accent) 7%, var(--paper));
  width: min(1180px, 100%);
  animation: settings-enter var(--motion-page) var(--ease-out) both;
}
.settings-personal {
  --settings-accent: #6d4ad1;
}
.settings-title {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 24px;
}
.settings-title h1 {
  margin: 0 0 8px;
  font:
    400 clamp(36px, 4vw, 48px) / 1.05 Georgia,
    serif;
  letter-spacing: -1.6px;
}
.settings-title p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}
.settings-body {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 34px;
  align-items: start;
}
.settings-index {
  position: sticky;
  top: 24px;
  width: 100%;
  min-width: 0;
  display: grid;
  gap: 4px;
}
.settings-index a {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 42px;
  padding: 9px 12px;
  border-left: 3px solid transparent;
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
  transition:
    color var(--motion-fast) ease,
    background-color var(--motion-fast) ease,
    transform var(--motion-fast) var(--ease-out);
}
.settings-index a span {
  width: 18px;
  text-align: center;
  font-size: 15px;
}
.settings-index a:hover {
  color: var(--ink);
  background: var(--soft);
  transform: translateX(2px);
}
.settings-index a.active {
  color: var(--settings-accent);
  background: var(--settings-tint);
  border-left-color: var(--settings-accent);
}
.settings-main {
  min-width: 0;
  border-top: 1px solid var(--line);
}
.settings-section {
  scroll-margin-top: 24px;
  padding: 26px 0 30px;
  border-bottom: 1px solid var(--line);
  animation: settings-section-enter var(--motion-page) var(--ease-out) both;
}
.settings-section:nth-child(2) {
  animation-delay: 35ms;
}
.settings-section:nth-child(3) {
  animation-delay: 70ms;
}
.settings-section:nth-child(4) {
  animation-delay: 105ms;
}
.settings-section:nth-child(5) {
  animation-delay: 140ms;
}
.settings-section:nth-child(6) {
  animation-delay: 175ms;
}
.settings-section:nth-child(7) {
  animation-delay: 210ms;
}
.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  margin-bottom: 22px;
}
.section-heading h2 {
  margin: 0 0 5px;
  font:
    400 24px/1.15 Georgia,
    serif;
  letter-spacing: -0.35px;
}
.section-heading p {
  max-width: 660px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
.row-action {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 4px;
  border: 0;
  background: transparent;
  color: var(--settings-accent);
  cursor: pointer;
  font-weight: 650;
}
.row-action span {
  transition: transform var(--motion-fast) var(--ease-out);
}
.row-action:hover span {
  transform: translateX(4px);
}
.company-identity,
.profile-identity {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) auto;
  align-items: center;
  gap: 20px;
  padding: 20px;
  background: var(--settings-tint);
  border: 1px solid color-mix(in srgb, var(--settings-accent) 15%, var(--line));
}
.settings-workspace .company-logo-setting {
  margin: 0;
  padding: 20px;
  border-top: 1px solid
    color-mix(in srgb, var(--settings-accent) 15%, var(--line));
}
.settings-workspace .company-logo-setting img {
  width: 76px;
  height: 76px;
  margin: 0;
}
.company-identity > img,
.company-logo-placeholder {
  width: 76px;
  height: 76px;
  object-fit: contain;
  display: grid;
  place-items: center;
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--settings-accent);
  font:
    600 23px Georgia,
    serif;
}
.company-identity h3,
.profile-identity h3 {
  margin: 0 0 4px;
  font:
    400 27px/1.15 Georgia,
    serif;
}
.company-identity p,
.profile-identity p {
  margin: 0 0 5px;
  color: var(--muted);
  font-size: 13px;
}
.company-identity small,
.profile-identity small {
  color: var(--muted);
}
.company-logo-actions,
.profile-photo-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px;
  margin: 0;
}
.profile-identity .settings-avatar {
  width: 76px;
  height: 76px;
  margin: 0;
  border: 3px solid var(--paper);
  box-shadow: 0 0 0 1px var(--line);
}
.section-note {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}
.summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 34px;
}
.summary-value {
  min-width: 0;
  display: grid;
  gap: 5px;
}
.summary-value span {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.summary-value strong {
  overflow-wrap: anywhere;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.45;
}
.inline-setting {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto;
  align-items: end;
  gap: 12px;
  max-width: 660px;
}
.inline-setting .field select {
  min-height: 44px;
}
.settings-workspace .feature-grid {
  grid-template-columns: repeat(3, minmax(150px, 1fr));
  border-radius: 0;
  border-color: var(--line);
}
.settings-workspace .feature-choice {
  position: relative;
  min-height: 58px;
  padding: 15px 16px;
  background: var(--paper);
  transition:
    background-color var(--motion-fast) ease,
    color var(--motion-fast) ease;
}
.settings-workspace .feature-choice:hover {
  background: var(--settings-tint);
}
.settings-workspace .feature-choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.settings-workspace .feature-choice > span {
  width: 34px;
  height: 20px;
  padding: 3px;
  flex: 0 0 auto;
  border-radius: 99px;
  background: var(--line);
  transition: background-color var(--motion-fast) ease;
}
.settings-workspace .feature-choice > span::after {
  content: "";
  display: block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--paper);
  box-shadow: 0 1px 3px rgb(12 18 28 / 18%);
  transition: transform var(--motion-fast) var(--ease-out);
}
.settings-workspace .feature-choice input:checked + span {
  background: var(--settings-accent);
}
.settings-workspace .feature-choice input:checked + span::after {
  transform: translateX(14px);
}
.settings-workspace .feature-choice input:focus-visible + span {
  outline: 3px solid color-mix(in srgb, var(--settings-accent) 25%, transparent);
  outline-offset: 3px;
}
.settings-workspace .feature-choice strong {
  font-size: 13px;
}
.settings-rows {
  border-top: 1px solid var(--line);
}
.settings-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  min-height: 64px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}
.settings-row:has(.provider-mark),
.settings-row:has(.session-mark) {
  grid-template-columns: 38px minmax(0, 1fr) auto;
}
.settings-row strong,
.settings-row small {
  display: block;
}
.settings-row strong {
  font-size: 13px;
}
.settings-row small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}
.provider-mark,
.session-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  background: var(--soft);
  color: var(--settings-accent);
  font-weight: 750;
}
.status-mark {
  padding: 5px 8px;
  background: var(--soft);
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.status-mark.success {
  color: #247451;
  background: #edf8f2;
}
.status-mark.pending {
  color: #93631e;
  background: #fff7e8;
}
.compact {
  padding: 8px 12px;
  font-size: 12px;
}
.settings-section > .quiet:last-child {
  margin-top: 12px;
  padding-left: 0;
}
.theme-choices {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.theme-choices button {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 8px;
  min-height: 58px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition:
    transform var(--motion-fast) var(--ease-out),
    border-color var(--motion-fast) ease,
    background-color var(--motion-fast) ease;
}
.theme-choices button:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--settings-accent) 48%, var(--line));
}
.theme-choices button.selected {
  border-color: var(--settings-accent);
  background: var(--settings-tint);
  color: var(--settings-accent);
}
.theme-choices button i {
  width: 14px;
  height: 14px;
  border: 1px solid var(--line);
  border-radius: 50%;
}
.theme-choices button.selected i {
  border: 4px solid var(--settings-accent);
}
.settings-personal .motion-toggle input:checked + span {
  background: var(--settings-accent);
}
.settings-empty {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 13px;
}
.danger-section {
  margin-top: 26px;
  padding: 24px;
  border: 1px solid color-mix(in srgb, var(--danger) 36%, var(--line));
  background: color-mix(in srgb, var(--danger) 3%, var(--paper));
}
.danger-section .section-heading {
  margin: 0;
}
.settings-alert {
  display: grid;
  gap: 5px;
  margin-top: 16px;
  color: var(--danger);
}
.settings-alert small {
  color: var(--muted);
}
@keyframes settings-enter {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}
@keyframes settings-section-enter {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}
@media (max-width: 900px) {
  .settings-body {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .settings-index {
    position: static;
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    overflow-x: auto;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--line);
  }
  .settings-index a {
    border-left: 0;
    border-bottom: 2px solid transparent;
  }
  .settings-index a.active {
    border-left-color: transparent;
    border-bottom-color: var(--settings-accent);
  }
}
@media (max-width: 620px) {
  .settings-title {
    margin-bottom: 18px;
  }
  .settings-title h1 {
    font-size: 34px;
  }
  .settings-section {
    padding: 22px 0 26px;
  }
  .section-heading {
    gap: 14px;
  }
  .section-heading h2 {
    font-size: 21px;
  }
  .company-identity,
  .profile-identity {
    grid-template-columns: 62px minmax(0, 1fr);
    gap: 14px;
    padding: 16px;
  }
  .company-identity > img,
  .company-logo-placeholder,
  .profile-identity .settings-avatar {
    width: 62px;
    height: 62px;
  }
  .settings-workspace .company-logo-setting img {
    width: 62px;
    height: 62px;
  }
  .company-logo-actions,
  .profile-photo-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
  .summary-grid,
  .theme-choices {
    grid-template-columns: 1fr;
  }
  .inline-setting {
    grid-template-columns: 1fr;
    align-items: stretch;
  }
  .settings-workspace .feature-grid {
    grid-template-columns: 1fr;
  }
  .settings-workspace .feature-choice,
  .settings-workspace .feature-choice:nth-child(3n),
  .settings-workspace .feature-choice:nth-last-child(-n + 3) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .settings-workspace .feature-choice:last-child {
    border-bottom: 0;
  }
  .settings-row:has(.provider-mark),
  .settings-row:has(.session-mark) {
    grid-template-columns: 36px minmax(0, 1fr);
  }
  .settings-row:has(.provider-mark) > :last-child,
  .settings-row:has(.session-mark) > :last-child {
    grid-column: 2;
    justify-self: start;
  }
  .danger-section {
    padding: 18px;
  }
  .danger-section .section-heading {
    flex-direction: column;
  }
}
