/* TSCO App — one visual language for the wholesale workspace. */
:root {
  --ui-bg: #f3f5f8;
  --ui-surface: #ffffff;
  --ui-ink: #172b40;
  --ui-muted: #607186;
  --ui-line: #dfe6ed;
  --ui-navy: #142a43;
  --ui-navy-2: #1d3b59;
  --ui-accent: #c92660;
  --ui-accent-hover: #a8174d;
  --ui-soft: #fcebf1;
  --ui-success: #166c53;
  --ui-shadow: 0 18px 55px rgba(22, 43, 64, 0.1);
  --bg: var(--ui-bg);
  --surface: var(--ui-surface);
  --surface-alt: #f8fafc;
  --ink: var(--ui-ink);
  --muted: var(--ui-muted);
  --border: var(--ui-line);
  --brand: var(--ui-navy);
  --side: var(--ui-navy);
}

:root[data-theme="dark"] {
  --ui-bg: #101b2a;
  --ui-surface: #1a2b3e;
  --ui-ink: #eaf0f6;
  --ui-muted: #abc0d1;
  --ui-line: #354b60;
  --ui-navy: #0b1726;
  --ui-navy-2: #19324e;
  --ui-accent: #f58cac;
  --ui-accent-hover: #ffc0d2;
  --ui-soft: #372738;
  --ui-success: #88d4b5;
  --ui-shadow: 0 20px 55px rgba(0, 0, 0, 0.24);
  --surface-alt: #22364a;
  --brand: #a9d9f2;
  --side: #0b1726;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ui-bg: #101b2a;
    --ui-surface: #1a2b3e;
    --ui-ink: #eaf0f6;
    --ui-muted: #abc0d1;
    --ui-line: #354b60;
    --ui-navy: #0b1726;
    --ui-navy-2: #19324e;
    --ui-accent: #f58cac;
    --ui-accent-hover: #ffc0d2;
    --ui-soft: #372738;
    --ui-success: #88d4b5;
    --ui-shadow: 0 20px 55px rgba(0, 0, 0, 0.24);
    --surface-alt: #22364a;
    --brand: #a9d9f2;
    --side: #0b1726;
  }
}
html {
  scroll-behavior: smooth;
}
body {
  background: var(--ui-bg);
  color: var(--ui-ink);
  font:
    14px/1.65 Vazir,
    Tahoma,
    sans-serif;
}
a {
  color: var(--ui-navy-2);
}
:root[data-theme="dark"] a {
  color: #a9d9f2;
}
.skip-link {
  position: fixed;
  z-index: 1000;
  top: -70px;
  right: 12px;
  background: var(--ui-surface);
  color: var(--ui-ink);
  padding: 10px 16px;
  border-radius: 10px;
}
.skip-link:focus {
  top: 12px;
}
.brand {
  display: inline-flex;
  flex-direction: row;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
  color: inherit;
  border: 0;
  padding: 0;
  white-space: nowrap;
}
.brand-word {
  display: inline-flex;
  gap: 5px;
  align-items: baseline;
  direction: ltr;
  font:
    800 22px/1.1 Vazir,
    Tahoma,
    sans-serif;
  letter-spacing: -0.04em;
}
.brand-word strong {
  color: var(--ui-accent);
}
.brand-symbol {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  display: inline-grid;
  place-items: center;
  background: var(--ui-accent);
  color: #fff;
  font:
    800 19px/1 Arial,
    sans-serif;
  box-shadow: 0 6px 16px rgba(201, 38, 96, 0.22);
}
.btn {
  background: var(--ui-navy-2);
  border-color: var(--ui-navy-2);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 9px;
  min-height: 38px;
}
.btn:hover {
  background: #294d6e;
  border-color: #294d6e;
  filter: none;
}
.btn.ghost {
  color: var(--ui-navy-2);
  background: var(--ui-surface);
  border-color: var(--ui-line);
}
:root[data-theme="dark"] .btn.ghost {
  color: #d0e6f6;
}
.theme-toggle {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--ui-line);
  border-radius: 10px;
  background: var(--ui-surface);
  color: var(--ui-ink);
  font-size: 20px;
}
:focus-visible {
  outline: 3px solid var(--ui-accent);
  outline-offset: 2px;
}

/* Public pages have no application sidebar. The form is the focus. */
body.guest-body {
  background:
    radial-gradient(
      circle at 8% 85%,
      rgba(201, 38, 96, 0.055),
      transparent 32%
    ),
    radial-gradient(
      circle at 92% 14%,
      rgba(43, 93, 138, 0.06),
      transparent 35%
    ),
    var(--ui-bg);
}
.public-shell {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}
.public-header {
  width: min(100%, 1200px);
  min-height: 72px;
  margin: 0 auto;
  padding: 16px 28px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.brand-public {
  color: var(--ui-ink);
  text-decoration: none;
}
.public-header-tag {
  color: var(--ui-muted);
  padding-right: 24px;
  border-right: 1px solid var(--ui-line);
  font-size: 12px;
}
.public-actions {
  margin-right: auto;
  display: flex;
  align-items: center;
  gap: 18px;
}
.public-actions a {
  font-size: 12px;
  color: var(--ui-ink);
  text-decoration: none;
  font-weight: 700;
}
.public-actions a:hover {
  color: var(--ui-accent);
}
.public-main {
  flex: 1;
  display: grid;
  place-items: center;
  width: 100%;
  padding: 20px 24px 36px;
}
.public-footer {
  text-align: center;
  font-size: 11px;
  color: var(--ui-muted);
  padding: 15px;
}
.public-footer span {
  color: var(--ui-accent);
  margin: 0 6px;
}
.auth-view {
  width: min(100%, 930px);
  margin: auto;
}
.auth-panel {
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(360px, 1fr);
  min-height: 530px;
  overflow: hidden;
  border: 1px solid var(--ui-line);
  border-radius: 22px;
  background: var(--ui-surface);
  box-shadow: var(--ui-shadow);
}
.auth-panel-register {
  width: min(100vw - 48px, 1020px);
  grid-template-columns: minmax(280px, 0.8fr) minmax(420px, 1.2fr);
}
.auth-panel-register .auth-form-pane {
  padding: 38px 42px;
}
.auth-story {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  padding: 36px 38px 25px;
  background: linear-gradient(145deg, #172e48, #102338 72%);
  color: #eef5fa;
}
.auth-story::before {
  content: "";
  position: absolute;
  width: 310px;
  height: 310px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.11);
  top: -165px;
  left: -90px;
  box-shadow:
    0 0 0 50px rgba(255, 255, 255, 0.025),
    0 0 0 105px rgba(255, 255, 255, 0.018);
  pointer-events: none;
}
.auth-story::after {
  content: "";
  width: 180px;
  height: 180px;
  position: absolute;
  left: -35px;
  bottom: -95px;
  border-radius: 50%;
  background: rgba(201, 38, 96, 0.12);
  filter: blur(10px);
  pointer-events: none;
}
.auth-story-mark {
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 9px;
  direction: ltr;
  justify-content: flex-end;
  font:
    800 21px/1.1 Vazir,
    sans-serif;
  white-space: nowrap;
}
.auth-story-mark .brand-mark {
  width: 30px;
  height: 30px;
  font-size: 16px;
  box-shadow: none;
}
.auth-story-mark small {
  display: block;
  font:
    600 8px/1 Arial,
    sans-serif;
  letter-spacing: 0.16em;
  color: #9fb9ce;
  margin-left: 7px;
}
.auth-story-content {
  z-index: 1;
  margin: auto 0;
}
.story-overline {
  margin: 0 0 14px;
  color: #f0a3bb;
  font-size: 11px;
  font-weight: 800;
}
.auth-story h2 {
  font-size: clamp(26px, 2.4vw, 36px);
  line-height: 1.45;
  letter-spacing: -0.035em;
  margin: 0 0 16px;
  color: #fff;
}
.auth-story h2 em {
  color: #f5a4bf;
  font-style: normal;
}
.auth-story-content > p:not(.story-overline) {
  color: #c4d5e1;
  font-size: 12px;
  max-width: 32ch;
  line-height: 1.9;
}
.auth-benefits {
  list-style: none;
  padding: 0;
  margin: 28px 0 0;
  display: grid;
  gap: 12px;
  color: #e8f0f5;
  font-size: 11px;
}
.auth-benefits li {
  display: flex;
  align-items: center;
  gap: 11px;
}
.auth-benefits li span {
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ef9fb9;
  border-radius: 6px;
  padding: 2px 6px;
  font:
    700 10px/1.5 Arial,
    sans-serif;
}
.auth-story-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid rgba(255, 255, 255, 0.13);
  padding-top: 17px;
  color: #a7bccd;
  font-size: 10px;
}
.auth-form-pane {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 54px 54px 42px;
}
.auth-form-heading .eyebrow {
  color: var(--ui-accent);
  letter-spacing: 0;
}
.auth-form-heading h1 {
  margin: 8px 0 5px;
  font-size: 28px;
  letter-spacing: -0.04em;
  line-height: 1.4;
}
.auth-form-heading p {
  margin: 0 0 28px;
  color: var(--ui-muted);
  font-size: 12px;
}
.auth-form {
  gap: 0;
}
.auth-form label {
  display: block;
  font-size: 12px;
  color: var(--ui-ink);
  font-weight: 700;
  margin: 0 0 7px;
}
.auth-form input:not([type="hidden"]) {
  width: 100%;
  min-height: 47px;
  margin: 0 0 18px;
  padding: 9px 14px;
  border: 1px solid var(--ui-line);
  border-radius: 10px;
  background: var(--ui-surface);
  color: var(--ui-ink);
  font-size: 13px;
}
.auth-form input::placeholder {
  color: #96a6b6;
}
.auth-form input:focus {
  outline: none;
  border-color: var(--ui-accent);
  box-shadow: 0 0 0 3px rgba(201, 38, 96, 0.13);
}
.auth-form small {
  display: block;
  color: var(--ui-muted);
  font-size: 10px;
  margin: -14px 0 16px;
}
.auth-error {
  position: static;
  margin: 0 0 18px;
  background: #fff1f3;
  color: #953947;
  border-color: #e8a5b1;
  box-shadow: none;
}
.auth-submit {
  width: 100%;
  min-height: 49px;
  display: flex;
  justify-content: space-between;
  background: var(--ui-accent);
  border-color: var(--ui-accent);
  padding: 10px 18px;
  margin-top: 4px;
  font-size: 13px;
}
.auth-submit:hover {
  background: var(--ui-accent-hover);
  border-color: var(--ui-accent-hover);
}
.auth-submit span {
  font-size: 20px;
  line-height: 1;
}
.auth-secondary {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--ui-line);
  padding-top: 19px;
  margin-top: 23px;
  color: var(--ui-muted);
  font-size: 11px;
}
.auth-secondary a {
  color: var(--ui-accent);
  font-weight: 800;
  text-decoration: none;
}
.auth-assist {
  color: var(--ui-muted);
  font-size: 10px;
  margin-top: 18px;
}
.auth-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 16px;
}
.auth-fields .span-2 {
  grid-column: 1 / -1;
}
.honeypot {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Internal B2B workspace */
.app-frame {
  grid-template-columns: 226px minmax(0, 1fr);
}
.side {
  background: var(--ui-navy);
  padding: 20px 11px 13px;
}
.side-header {
  padding: 2px 9px 17px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
}
.brand-side {
  color: #fff;
  text-decoration: none;
}
.brand-side .brand-word strong {
  color: #ff8eb3;
}
.side-caption {
  margin: -10px 13px 3px;
  color: #b7cad9;
  font-size: 11px;
}
.side-nav {
  gap: 4px;
}
.side-nav a,
.side-logout {
  min-height: 43px;
  border-radius: 9px;
  color: #bfcede;
  gap: 12px;
}
.side-nav a:hover,
.side-nav a[aria-current="page"],
.side-logout:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}
.side-nav a[aria-current="page"] {
  border-inline-start: 3px solid #f38bae;
  background: rgba(255, 255, 255, 0.12);
}
.nav-group {
  color: #b4c7d8;
  font-size: 10px;
  letter-spacing: 0;
  padding-top: 16px;
}
.nav-icon {
  display: grid;
  place-items: center;
  width: 22px;
  flex: 0 0 22px;
}
.nav-icon svg {
  width: 19px;
  height: 19px;
}
.side-bottom {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.side-role {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #d7e6ef;
  padding: 8px 12px 12px;
  font-size: 11px;
}
.side-role-dot {
  width: 7px;
  height: 7px;
  background: #83d7bb;
  border-radius: 50%;
}
.side-collapse {
  margin-top: 8px;
}
.topbar {
  min-height: 70px;
  padding: 9px clamp(20px, 2.3vw, 36px);
  background: var(--ui-surface);
}
.topbar-context {
  display: grid;
  gap: 2px;
}
.topbar-overline {
  color: var(--ui-muted);
  font-size: 10px;
}
.topbar-overline span {
  margin: 0 5px;
  color: var(--ui-accent);
}
.page-title {
  font-size: 17px;
  color: var(--ui-ink);
}
.quick-search {
  margin-inline-start: auto;
  max-width: 340px;
  flex: 0 1 340px;
  position: relative;
}
.quick-search input {
  height: 38px;
  border-radius: 9px;
  padding-inline-start: 32px;
  color: var(--ui-ink);
}
.quick-search .search-icon {
  position: absolute;
  right: 10px;
  font-size: 21px;
  color: var(--ui-muted);
}
.quick-search kbd {
  position: absolute;
  left: 10px;
  border: 1px solid var(--ui-line);
  color: var(--ui-muted);
  background: var(--ui-surface);
  padding: 0 6px;
  border-radius: 5px;
  font:
    11px/19px Arial,
    sans-serif;
}
.topbar-actions {
  display: flex;
  gap: 9px;
  align-items: center;
  margin-inline-start: 2px;
}
.role-badge {
  background: var(--ui-bg);
  border: 1px solid var(--ui-line);
  color: var(--ui-muted);
  font-size: 11px;
}
.content {
  max-width: 1600px;
  padding: 25px clamp(20px, 2.3vw, 36px) 48px;
}
.card {
  border: 1px solid var(--ui-line);
  box-shadow: 0 4px 24px rgba(16, 41, 65, 0.045);
  border-radius: 13px;
}
.workspace-head {
  margin-bottom: 17px;
}
.workspace-head h2 {
  font-size: 18px;
  color: var(--ui-ink);
}
.list-summary {
  color: var(--ui-muted);
}
.toolbar {
  background: var(--surface-alt);
  border-radius: 10px;
  padding: 12px;
}
.table-wrap {
  border-radius: 10px;
}
.data-table th {
  color: var(--ui-muted);
  font-size: 11px;
}
.data-table td {
  padding-top: 10px;
  padding-bottom: 10px;
}
.row-product {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ui-ink);
  text-decoration: none;
  min-width: 220px;
}
.row-product:hover .row-title {
  color: var(--ui-accent);
}
.row-product > span:last-child {
  min-width: 0;
}
.row-title {
  display: block;
  line-height: 1.55;
}
.row-sub {
  display: block;
}
.table-image.placeholder {
  display: grid;
  place-items: center;
  color: var(--ui-accent);
}
.currency {
  color: var(--ui-muted);
  font-size: 10px;
}
.status-chip {
  border-radius: 7px;
}
.kpi-row {
  gap: 12px;
}
.kpi {
  border-radius: 11px;
  box-shadow: 0 3px 16px rgba(16, 41, 65, 0.04);
}
.kpi.accent {
  border-color: var(--ui-line);
  border-top: 3px solid var(--ui-accent);
}
.kpi-value {
  color: var(--ui-ink);
}

@media (max-width: 1000px) {
  .app-frame {
    grid-template-columns: 198px minmax(0, 1fr);
  }
  .public-header {
    padding: 14px 24px;
  }
  .auth-form-pane {
    padding: 40px 30px;
  }
}
@media (max-width: 760px) {
  .public-header {
    padding: 13px 17px;
    min-height: 62px;
  }
  .public-header-tag {
    display: none;
  }
  .public-actions {
    gap: 10px;
  }
  .public-actions a {
    font-size: 11px;
  }
  .public-main {
    padding: 14px 15px 25px;
    align-items: center;
  }
  .auth-panel,
  .auth-panel-register {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr;
    border-radius: 17px;
    min-height: 0;
  }
  .auth-story {
    padding: 22px 24px;
    min-height: 120px;
  }
  .auth-story-content {
    margin: 16px 0 0;
  }
  .auth-story-content h2 {
    font-size: 21px;
    margin: 0;
  }
  .auth-story-content > p:not(.story-overline),
  .auth-benefits,
  .auth-story-footer {
    display: none;
  }
  .auth-form-pane,
  .auth-panel-register .auth-form-pane {
    padding: 27px 24px 30px;
  }
  .auth-form-heading p {
    margin-bottom: 20px;
  }
  .auth-fields {
    grid-template-columns: 1fr 1fr;
  }
  .app-frame {
    display: block;
  }
  .topbar {
    gap: 11px;
    min-height: 62px;
  }
  .topbar-context {
    min-width: 0;
  }
  .page-title {
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .topbar-actions {
    margin-inline-start: auto;
  }
  .side {
    width: min(285px, 85vw);
  }
  .quick-search,
  .role-badge {
    display: none;
  }
  .content {
    padding: 18px 14px 45px;
  }
  .toolbar {
    background: transparent;
    padding: 0;
  }
  .data-table .row-product {
    min-width: 0;
  }
  .table-image {
    flex: 0 0 38px;
  }
}
@media (max-width: 480px) {
  .brand-word {
    font-size: 18px;
  }
  .brand-symbol {
    width: 32px;
    height: 32px;
  }
  .public-actions a {
    font-size: 10px;
  }
  .auth-story {
    padding: 18px 20px;
  }
  .auth-form-pane,
  .auth-panel-register .auth-form-pane {
    padding: 22px 19px 24px;
  }
  .auth-form-heading h1 {
    font-size: 24px;
  }
  .auth-fields {
    grid-template-columns: 1fr;
  }
  .auth-fields .span-2 {
    grid-column: auto;
  }
  .auth-secondary {
    flex-wrap: wrap;
  }
}
/* Category links retain their nested list structure for screen readers. */
.category-picker {
  position: relative;
  width: 100%;
  min-width: 0;
  border: 1px solid var(--ui-line);
  border-radius: 10px;
  background: var(--ui-surface);
  color: var(--ui-ink);
  font-size: 12px;
}
.category-picker[open] {
  border-color: var(--ui-accent);
  box-shadow: 0 0 0 3px rgba(201, 38, 96, 0.12);
}
.category-picker > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 40px;
  padding: 8px 12px;
  cursor: pointer;
  list-style: none;
  font-weight: 700;
}
.category-picker > summary::-webkit-details-marker {
  display: none;
}
.category-picker > summary::after {
  content: "";
  width: 7px;
  height: 7px;
  border-inline-end: 2px solid var(--ui-muted);
  border-bottom: 2px solid var(--ui-muted);
  transform: rotate(45deg);
  transition: transform 0.15s ease;
}
.category-picker[open] > summary::after {
  transform: rotate(-135deg);
}
.category-picker-panel {
  position: absolute;
  inset-inline: 0;
  top: calc(100% + 6px);
  z-index: 40;
  max-height: min(420px, 60vh);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 6px;
  border: 1px solid var(--ui-line);
  border-radius: 12px;
  background: var(--ui-surface);
  box-shadow: 0 14px 34px rgba(15, 30, 45, 0.18);
}
@media (min-width: 761px) {
  .category-picker-panel {
    min-width: 280px;
  }
}
.category-all {
  display: block;
  margin: 0 0 4px;
}
.category-picker a,
.category-tree a {
  display: block;
  padding: 7px 10px;
  border-radius: 7px;
  color: var(--ui-ink);
  text-decoration: none;
  font-size: 12px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.category-tree {
  list-style: none;
  margin: 0;
  padding: 0;
}
.category-tree .category-tree {
  margin-inline-start: 10px;
  padding-inline-start: 9px;
  border-inline-start: 1px solid var(--ui-line);
}
.category-tree a {
  color: var(--ui-muted);
  font-weight: 600;
}
/* Primary categories are collapsible sections; their own link sits in the summary row. */
.category-primary {
  border-top: 1px solid var(--ui-line);
}
.category-primary:first-of-type {
  border-top: none;
}
.category-primary > .category-tree {
  margin: 0 7px 6px;
}
.category-primary-label {
  display: flex;
  align-items: center;
  list-style: none;
  cursor: pointer;
  padding: 2px 3px;
  border-radius: 7px;
}
.category-primary-label::-webkit-details-marker {
  display: none;
}
.category-primary-label::before {
  content: "›";
  display: inline-block;
  margin-inline-end: 6px;
  color: var(--ui-muted);
  transition: transform .15s ease;
}
.category-primary[open] > .category-primary-label::before {
  transform: rotate(90deg);
}
.category-primary-label a,
.category-primary-link {
  flex: 1;
  display: block;
  padding: 7px 10px;
  border-radius: 7px;
  text-decoration: none;
  font-size: 12px;
  background: var(--surface-alt);
  font-weight: 800;
  color: var(--ui-ink);
}
.category-primary-label.active a,
.category-primary-link.active {
  color: var(--ui-accent);
}
.category-picker a:hover,
.category-picker a:focus-visible {
  background: var(--ui-soft);
  color: var(--ui-accent);
}
.category-picker a.active,
.category-picker a[aria-current="page"] {
  border-inline-start: 3px solid var(--ui-accent);
  background: var(--ui-soft);
  color: var(--ui-accent);
  font-weight: 800;
}

/* The admin tree nests details elements; indent each level once. */
.card .category-node {
  padding-inline-start: 0;
}
.card > .category-node {
  margin: 10px 0;
  padding: 10px 12px;
  border: 1px solid var(--ui-line);
  border-radius: 9px;
  background: var(--ui-surface);
}
.card .category-node > .category-node {
  margin: 6px 0 0;
  margin-inline-start: 12px;
  padding-inline-start: 12px;
  border-inline-start: 2px solid var(--ui-line);
}
.card .category-summary {
  display: list-item;
  width: fit-content;
  max-width: 100%;
  padding: 4px 2px;
  cursor: pointer;
  line-height: 1.8;
}
.card .category-summary::marker {
  color: var(--ui-accent);
}
.card .category-summary strong,
.card .category-summary .muted {
  margin-inline-end: 8px;
}
.card > .category-node > .category-summary strong {
  color: var(--ui-ink);
  font-size: 14px;
}
.card .category-node > .category-node > .category-summary strong {
  color: var(--ui-muted);
  font-size: 12px;
}
.card .category-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 5px 0 8px;
}

/* Registration steps: the ordered list conveys progress even without color. */
.auth-panel-register .steps {
  --step-size: 32px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  list-style: none;
  padding: 0;
  margin: 18px 0 26px;
}
.auth-panel-register .steps li {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--ui-muted);
}
.auth-panel-register .steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  top: calc(var(--step-size) / 2 - 1px);
  inset-inline-start: calc(50% + var(--step-size) / 2 + 3px);
  width: calc(100% - var(--step-size) - 6px);
  height: 2px;
  background: var(--ui-line);
}
.auth-panel-register .steps li.done::after {
  background: var(--ui-success);
}
.auth-panel-register .step-dot {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: var(--step-size);
  height: var(--step-size);
  flex: none;
  border: 2px solid var(--ui-line);
  border-radius: 50%;
  background: var(--surface-alt);
  color: var(--ui-muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}
.auth-panel-register .steps li.done .step-dot {
  border-color: var(--ui-success);
  background: var(--ui-success);
  color: var(--ui-surface);
}
.auth-panel-register .steps li.current .step-dot {
  border-color: var(--ui-accent);
  background: var(--ui-accent);
  color: var(--ui-surface);
  box-shadow: 0 0 0 4px var(--ui-soft);
}
.auth-panel-register .step-label {
  width: 100%;
  text-align: center;
  overflow-wrap: anywhere;
  font-size: 11px;
  line-height: 1.55;
}
.auth-panel-register .steps li.done .step-label {
  color: var(--ui-success);
  font-weight: 700;
}
.auth-panel-register .steps li.current .step-label {
  color: var(--ui-ink);
  font-weight: 800;
}
@media (max-width: 480px) {
  .auth-panel-register .steps {
    --step-size: 28px;
    margin: 16px 0 22px;
  }
  .auth-panel-register .step-label {
    font-size: 10px;
  }
}
.auth-notice {
  position: static;
  margin: 0 0 18px;
  background: #eaf7f0;
  color: #166c53;
  border-color: #9fd6bd;
  box-shadow: none;
}
.auth-step-note {
  color: var(--ui-muted);
  font-size: 12px;
  margin: 0 0 18px;
}
.inline-form {
  display: inline;
  margin: 0;
}
.link-button {
  border: 0;
  background: none;
  padding: 0;
  color: var(--ui-accent);
  font-weight: 800;
  font-size: 11px;
  cursor: pointer;
}
.link-button:hover {
  text-decoration: underline;
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
