:root {
  --brand-950: #3b1017;
  --brand-900: #58151f;
  --brand-800: #741b29;
  --brand-700: #8d2332;
  --brand-100: #f7e8ea;
  --brand-50: #fcf5f6;
  --accent: #d3a039;
  --ink: #18202c;
  --ink-soft: #3f4b5d;
  --muted: #667085;
  --border: #d9dee7;
  --border-strong: #c3cad5;
  --surface: #ffffff;
  --surface-soft: #f8f9fb;
  --page: #f2f4f7;
  --success: #18704b;
  --success-soft: #e8f5ee;
  --danger: #b42318;
  --danger-soft: #fff0ee;
  --warning-soft: #fff7e0;
  --shadow-sm: 0 1px 2px rgb(16 24 40 / 6%), 0 1px 3px rgb(16 24 40 / 8%);
  --shadow-md: 0 12px 32px rgb(16 24 40 / 10%);
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --content-width: 1240px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--page);
  font-synthesis: none;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button,
input,
select,
textarea {
  font: inherit;
}

a {
  color: var(--brand-700);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--brand-900);
}

img {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  color: var(--ink);
  line-height: 1.18;
  text-wrap: balance;
}

h1 {
  margin-bottom: 0.45rem;
  font-size: clamp(1.8rem, 3vw, 2.45rem);
  letter-spacing: -0.035em;
}

h2 {
  margin-bottom: 0.35rem;
  font-size: clamp(1.18rem, 2vw, 1.45rem);
  letter-spacing: -0.018em;
}

h3 {
  margin-bottom: 0.4rem;
  font-size: 1.06rem;
}

code,
.inline-code {
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
  font-size: 0.9em;
}

.visually-hidden {
  position: absolute !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;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.7rem 1rem;
  transform: translateY(-180%);
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: #fff;
  font-weight: 700;
  transition: transform 140ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

:focus-visible {
  outline: 3px solid rgb(211 160 57 / 65%);
  outline-offset: 2px;
}

.site-header {
  position: relative;
  z-index: 10;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 1px 4px rgb(16 24 40 / 4%);
}

.site-header__inner,
.primary-nav__inner,
.site-footer__inner {
  width: min(calc(100% - 2rem), var(--content-width));
  margin-inline: auto;
}

.site-header__inner {
  display: flex;
  min-height: 76px;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--ink);
  text-decoration: none;
}

.brand:hover {
  color: var(--ink);
}

.brand__mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 11px;
  background: linear-gradient(145deg, var(--brand-700), var(--brand-950));
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / 12%);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand__text strong {
  font-size: 0.98rem;
  letter-spacing: -0.01em;
}

.brand__text small {
  margin-top: 0.18rem;
  color: var(--muted);
  font-size: 0.77rem;
}

.site-header__account {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.organization-label {
  display: inline-flex;
  min-width: 0;
  max-width: 320px;
  align-items: center;
  gap: 0.5rem;
  color: var(--ink-soft);
  font-size: 0.88rem;
  font-weight: 650;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.organization-label__dot {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 3px var(--success-soft);
}

.logout-form {
  margin: 0;
}

.account-link {
  display: flex;
  min-width: 0;
  flex-direction: column;
  color: var(--ink);
  line-height: 1.2;
  text-align: right;
  text-decoration: none;
}

.account-link:hover {
  color: var(--brand-800);
}

.account-link span {
  max-width: 210px;
  overflow: hidden;
  font-size: 0.86rem;
  font-weight: 720;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-link small {
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.7rem;
}

.account-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
}

.user-cell {
  display: flex;
  min-width: 230px;
  align-items: center;
  gap: 0.75rem;
}

.user-cell__mark {
  display: grid;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: var(--brand-100);
  color: var(--brand-800);
  font-size: 0.82rem;
  font-weight: 800;
}

.user-cell div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.user-cell small {
  max-width: 380px;
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.role-badge {
  display: inline-flex;
  padding: 0.28rem 0.58rem;
  border-radius: 999px;
  background: #eef2f6;
  color: var(--ink-soft);
  font-size: 0.76rem;
  font-weight: 760;
}

.role-badge--admin {
  background: var(--brand-100);
  color: var(--brand-800);
}

.primary-nav {
  border-top: 1px solid #edf0f4;
}

.primary-nav__inner {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.primary-nav__inner::-webkit-scrollbar {
  display: none;
}

.primary-nav a {
  position: relative;
  display: inline-flex;
  min-height: 48px;
  flex: 0 0 auto;
  align-items: center;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 650;
  text-decoration: none;
}

.primary-nav a:hover,
.primary-nav a.is-active {
  color: var(--brand-800);
}

.primary-nav a.is-active::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--brand-700);
  content: "";
}

.organization-switcher {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 0.45rem;
  margin-left: auto;
}

.organization-switcher select {
  width: auto;
  min-width: 160px;
  max-width: 260px;
  min-height: 36px;
  padding: 0.42rem 1.8rem 0.42rem 0.65rem;
  border-color: var(--border);
  font-size: 0.8rem;
  font-weight: 650;
}

.page-shell {
  width: min(calc(100% - 2rem), var(--content-width));
  min-height: calc(100vh - 196px);
  margin-inline: auto;
  padding-block: clamp(1.75rem, 4vw, 3rem) 4rem;
}

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 0.8rem;
}

.site-footer__inner {
  display: flex;
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.eyebrow {
  margin-bottom: 0.45rem;
  color: var(--brand-700);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 1.75rem;
}

.page-heading--form {
  align-items: center;
}

.page-heading__lead {
  max-width: 680px;
  margin-bottom: 0;
  color: var(--muted);
}

.catalog-scope-note {
  display: flex;
  align-items: baseline;
  gap: 0.65rem;
  margin: -0.7rem 0 1.4rem;
  padding: 0.82rem 1rem;
  border: 1px solid #cbdedb;
  border-radius: 10px;
  background: #f2f9f7;
  color: #245e58;
  font-size: 0.88rem;
  line-height: 1.45;
}

.catalog-scope-note strong {
  flex: 0 0 auto;
}

.page-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.65rem;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1.15rem;
  color: var(--muted);
  font-size: 0.86rem;
}

.breadcrumbs a {
  color: var(--muted);
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.66rem 1rem;
  border: 1px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 720;
  line-height: 1.1;
  text-align: center;
  text-decoration: none;
  transition: background-color 140ms ease, border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button:active {
  transform: translateY(0);
}

.button--primary {
  border-color: var(--brand-700);
  background: var(--brand-700);
  box-shadow: 0 1px 2px rgb(59 16 23 / 18%);
  color: #fff;
}

.button--primary:hover {
  border-color: var(--brand-900);
  background: var(--brand-900);
  color: #fff;
}

.button--secondary {
  border-color: #d7b5ba;
  background: var(--brand-50);
  color: var(--brand-800);
}

.button--secondary:hover {
  border-color: #c58d96;
  background: var(--brand-100);
  color: var(--brand-900);
}

.button--danger {
  border-color: #e4aaa4;
  background: var(--danger-soft);
  color: var(--danger);
}

.button--danger:hover {
  border-color: var(--danger);
  background: #ffe3df;
  color: #8e1b13;
}

.button--quiet {
  border-color: var(--border);
  background: var(--surface);
  color: var(--ink-soft);
}

.button--quiet:hover {
  border-color: var(--border-strong);
  background: var(--surface-soft);
  color: var(--ink);
}

.button--small {
  min-height: 36px;
  padding: 0.48rem 0.75rem;
  border-radius: 8px;
  font-size: 0.84rem;
}

.button--wide {
  width: 100%;
}

.text-link {
  flex: 0 0 auto;
  font-size: 0.88rem;
  font-weight: 700;
}

.panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.panel__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 1.5rem;
  border-bottom: 1px solid var(--border);
}

.panel__header--compact {
  align-items: center;
}

.panel__header h2,
.panel__header p {
  margin-bottom: 0;
}

.panel__header p:not(.eyebrow) {
  color: var(--muted);
  font-size: 0.86rem;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.metric-grid--five {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.metric-card {
  position: relative;
  display: flex;
  min-height: 168px;
  flex-direction: column;
  padding: 1.3rem;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  color: var(--ink);
  text-decoration: none;
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

a.metric-card:hover {
  border-color: #c3a1a7;
  box-shadow: 0 8px 24px rgb(16 24 40 / 9%);
  color: var(--ink);
  transform: translateY(-2px);
}

.metric-card::after {
  position: absolute;
  top: -34px;
  right: -34px;
  width: 104px;
  height: 104px;
  border-radius: 50%;
  background: var(--brand-50);
  content: "";
}

.metric-card--positive::after {
  background: var(--success-soft);
}

.metric-card--neutral::after {
  background: #eef1f5;
}

.metric-card__label {
  position: relative;
  z-index: 1;
  color: var(--muted);
  font-size: 0.83rem;
  font-weight: 700;
}

.metric-card strong {
  position: relative;
  z-index: 1;
  margin-top: 0.55rem;
  font-size: clamp(2rem, 4vw, 2.6rem);
  letter-spacing: -0.04em;
  line-height: 1;
}

.metric-card__link {
  position: relative;
  z-index: 1;
  margin-top: auto;
  color: var(--brand-700);
  font-size: 0.78rem;
  font-weight: 700;
}

.metric-card--neutral .metric-card__link,
.metric-card--positive .metric-card__link {
  color: var(--muted);
}

.dashboard-section {
  overflow: hidden;
}

.dashboard-onboarding {
  display: grid;
  min-height: 520px;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.72fr);
  align-items: center;
  gap: clamp(2rem, 7vw, 6rem);
}

.dashboard-onboarding__copy > p:not(.eyebrow) {
  max-width: 610px;
  margin-bottom: 1.5rem;
  color: var(--muted);
  font-size: 1.02rem;
}

.dashboard-onboarding__steps {
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
}

.dashboard-onboarding__steps ol {
  display: grid;
  gap: 1.1rem;
  margin: 1.25rem 0 0;
  padding: 0;
  list-style: none;
}

.dashboard-onboarding__steps li {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
}

.dashboard-onboarding__steps li > span {
  display: grid;
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 9px;
  background: var(--brand-50);
  color: var(--brand-700);
  font-size: 0.78rem;
  font-weight: 800;
}

.dashboard-onboarding__steps strong,
.dashboard-onboarding__steps small {
  display: block;
}

.dashboard-onboarding__steps strong {
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.dashboard-onboarding__steps small {
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.76rem;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(210px, 1.4fr) minmax(170px, 0.8fr) minmax(155px, 0.65fr) auto;
  align-items: end;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: #fcfcfd;
}

.filter-bar .field > label {
  font-size: 0.72rem;
}

.filter-bar input,
.filter-bar select {
  min-height: 40px;
  padding-block: 0.5rem;
  font-size: 0.84rem;
}

.filter-bar__actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
}

.table-scroll {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0;
  font-size: 0.9rem;
}

.data-table th,
.data-table td {
  padding: 0.95rem 1rem;
  border-bottom: 1px solid #e8ebf0;
  text-align: left;
  vertical-align: middle;
}

.data-table th:first-child,
.data-table td:first-child {
  padding-left: 1.5rem;
}

.data-table th:last-child,
.data-table td:last-child {
  padding-right: 1.5rem;
}

.data-table thead th {
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 780;
  letter-spacing: 0.045em;
  text-transform: uppercase;
  white-space: nowrap;
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-table tbody tr:hover {
  background: #fcfcfd;
}

.data-table .numeric {
  text-align: right;
  white-space: nowrap;
}

.table-note {
  display: block;
  margin-top: 0.1rem;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 500;
}

.data-table .table-action {
  text-align: right;
}

.data-table .table-action > a:not(.button) {
  font-size: 0.84rem;
  font-weight: 700;
}

.product-cell {
  display: flex;
  min-width: 190px;
  align-items: center;
  gap: 0.75rem;
}

.product-cell > div {
  min-width: 0;
}

.product-cell strong,
.product-cell small {
  display: block;
}

.product-cell small {
  margin-top: 0.18rem;
  color: var(--muted);
  font-size: 0.76rem;
  overflow-wrap: anywhere;
}

.product-thumb {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-soft);
  object-fit: cover;
}

.product-thumb--small {
  width: 40px;
  height: 40px;
  border-radius: 8px;
}

.product-thumb--placeholder {
  display: grid;
  place-items: center;
  background: var(--brand-50);
  color: var(--brand-700);
  font-weight: 800;
}

.status {
  display: inline-flex;
  min-height: 25px;
  align-items: center;
  padding: 0.22rem 0.55rem;
  border-radius: 999px;
  background: #edf0f4;
  color: #566173;
  font-size: 0.72rem;
  font-weight: 750;
  white-space: nowrap;
}

.status--active {
  background: var(--success-soft);
  color: var(--success);
}

.stock-value--negative {
  color: var(--danger);
  font-weight: 750;
}

.stock-quantity {
  font-size: 1.08rem;
  font-variant-numeric: tabular-nums;
}

.stock-quantity--zero {
  color: #8a641e;
}

.stock-quantity--negative {
  color: var(--danger);
}

.stock-state {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  padding: 0.23rem 0.58rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 760;
  white-space: nowrap;
}

.stock-state--positive {
  background: var(--success-soft);
  color: var(--success);
}

.stock-state--zero {
  background: var(--warning-soft);
  color: #7b5711;
}

.stock-state--negative {
  background: var(--danger-soft);
  color: var(--danger);
}

.inline-code {
  display: inline-block;
  padding: 0.18rem 0.4rem;
  border-radius: 5px;
  background: #f0f2f5;
  color: var(--ink-soft);
}

.empty-state {
  display: flex;
  min-height: 310px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 2rem;
  text-align: center;
}

.empty-state__mark {
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  margin-bottom: 1rem;
  border-radius: 15px;
  background: var(--brand-50);
  color: var(--brand-700);
  font-size: 1.7rem;
  font-weight: 300;
}

.empty-state p {
  max-width: 470px;
  margin-bottom: 1.25rem;
  color: var(--muted);
}

.empty-state__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem;
}

.flash-messages {
  position: relative;
  z-index: 5;
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 1rem auto -0.5rem;
}

.flash-message {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.8rem 1rem;
  border: 1px solid #b9dcca;
  border-radius: 10px;
  background: var(--success-soft);
  color: #135b3e;
  box-shadow: var(--shadow-sm);
}

.flash-message + .flash-message {
  margin-top: 0.5rem;
}

.flash-message p {
  margin: 0;
}

.flash-message__icon {
  width: 10px;
  height: 10px;
  flex: 0 0 auto;
  margin-top: 0.42rem;
  border-radius: 50%;
  background: currentColor;
}

.flash-message--error {
  border-color: #fac5bd;
  background: var(--danger-soft);
  color: var(--danger);
}

.flash-message--warning {
  border-color: #efdaa1;
  background: var(--warning-soft);
  color: #7b5711;
}

.editor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  align-items: start;
  gap: 1.25rem;
}

.editor-main {
  display: grid;
  min-width: 0;
  gap: 1rem;
}

.editor-sidebar {
  display: grid;
  position: sticky;
  top: 1.25rem;
  gap: 1rem;
}

.form-section {
  padding: clamp(1.15rem, 2.5vw, 1.6rem);
}

.form-section__header {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  align-items: start;
  gap: 0.85rem;
  margin-bottom: 1.35rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e8ebf0;
}

.form-section__header--actions {
  grid-template-columns: 36px minmax(0, 1fr) auto;
  align-items: center;
}

.form-section__header h2,
.form-section__header p {
  margin-bottom: 0;
}

.form-section__header p {
  color: var(--muted);
  font-size: 0.86rem;
}

.section-number {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 10px;
  background: var(--brand-50);
  color: var(--brand-700);
  font-size: 0.82rem;
  font-weight: 800;
}

.form-grid {
  display: grid;
  gap: 1.1rem;
}

.form-grid--two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field--span-2 {
  grid-column: 1 / -1;
}

.stack-form {
  display: grid;
  gap: 1.05rem;
}

.field {
  min-width: 0;
}

.field > label,
.field > .label {
  display: block;
  margin-bottom: 0.38rem;
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 720;
}

.field-label-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.38rem;
}

.field-label-row label {
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 720;
}

.field-label-row .text-link {
  flex: 0 0 auto;
  font-size: 0.76rem;
}

.field-help--warning {
  color: #7b5711;
}

.required-mark {
  color: var(--brand-700);
}

.optional-label {
  margin-left: 0.3rem;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 500;
}

input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
select,
textarea {
  width: 100%;
  min-height: 44px;
  padding: 0.64rem 0.75rem;
  border: 1px solid var(--border-strong);
  border-radius: 9px;
  outline: none;
  background: var(--surface);
  color: var(--ink);
  line-height: 1.25;
  transition: border-color 120ms ease, box-shadow 120ms ease;
}

textarea {
  min-height: 108px;
  resize: vertical;
}

select {
  padding-right: 2rem;
}

input::placeholder,
textarea::placeholder {
  color: #98a1b2;
}

input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):focus,
select:focus,
textarea:focus {
  border-color: var(--brand-700);
  box-shadow: 0 0 0 3px rgb(141 35 50 / 12%);
}

input[disabled],
select[disabled],
textarea[disabled] {
  cursor: not-allowed;
  background: #f1f3f6;
  color: var(--muted);
}

input[type="file"] {
  width: 100%;
  color: var(--muted);
  font-size: 0.84rem;
}

input[type="file"]::file-selector-button {
  min-height: 38px;
  margin-right: 0.7rem;
  padding: 0.45rem 0.75rem;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--ink-soft);
  cursor: pointer;
  font-weight: 700;
}

input[type="checkbox"] {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
  margin: 0.1rem 0 0;
  accent-color: var(--brand-700);
}

.field-help {
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.4;
}

.field-error,
.errorlist {
  margin: 0.35rem 0 0;
  color: var(--danger);
  font-size: 0.78rem;
  font-weight: 650;
}

.errorlist {
  padding-left: 1.1rem;
}

.field--error input:not([type="checkbox"]),
.field--error select,
.field--error textarea {
  border-color: var(--danger);
  background: #fffafa;
}

.input-with-suffix {
  display: flex;
  align-items: stretch;
}

.input-with-suffix input {
  border-radius: 9px 0 0 9px !important;
}

.input-with-suffix > span {
  display: grid;
  min-width: 52px;
  place-items: center;
  border: 1px solid var(--border-strong);
  border-left: 0;
  border-radius: 0 9px 9px 0;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 750;
}

.check-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.check-control {
  display: flex;
  min-width: 0;
  align-items: flex-start;
  gap: 0.72rem;
  padding: 0.9rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-soft);
  cursor: pointer;
}

.check-control:hover {
  border-color: var(--border-strong);
}

.check-control span,
.check-control strong,
.check-control small {
  display: block;
}

.check-control strong {
  color: var(--ink-soft);
  font-size: 0.86rem;
}

.check-control small {
  margin-top: 0.18rem;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 400;
  line-height: 1.4;
}

.check-control--compact {
  display: inline-flex;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink-soft);
  font-size: 0.82rem;
}

.check-control--inline {
  min-height: 44px;
  align-items: center;
  align-self: end;
  justify-content: center;
  padding: 0.58rem;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

.thumbnail-editor {
  display: grid;
  grid-template-columns: 124px minmax(0, 1fr);
  align-items: center;
  gap: 1.2rem;
}

.thumbnail-preview {
  display: grid;
  width: 124px;
  aspect-ratio: 1;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-soft);
}

.thumbnail-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.thumbnail-preview--empty {
  border-style: dashed;
  color: var(--muted);
  font-size: 0.76rem;
}

.thumbnail-editor__fields {
  display: grid;
  gap: 0.9rem;
}

.code-list {
  display: grid;
  gap: 0.65rem;
}

.code-list__empty {
  margin: 0;
  padding: 1rem;
  border: 1px dashed var(--border-strong);
  border-radius: 10px;
  color: var(--muted);
  font-size: 0.84rem;
  text-align: center;
}

.code-row {
  display: grid;
  grid-template-columns: minmax(170px, 1.55fr) minmax(105px, 0.8fr) minmax(140px, 1fr) auto auto;
  align-items: start;
  gap: 0.65rem;
  min-width: 0;
  margin: 0;
  padding: 0.85rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-soft);
}

.code-row.is-marked-for-removal {
  border-color: #e7a9a1;
  background: var(--danger-soft);
  opacity: 0.78;
}

.code-row.is-marked-for-removal .field {
  text-decoration: line-through;
}

.code-row__alert,
.code-row__wide {
  grid-column: 1 / -1;
}

.code-row .field > label {
  font-size: 0.72rem;
}

.editor-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
  padding-top: 0.35rem;
}

.editor-actions--inside {
  padding-top: 0.25rem;
  border-top: 1px solid #e8ebf0;
}

.stock-panel,
.help-panel {
  padding: 1.25rem;
}

#stock-adjustment {
  scroll-margin-top: 1rem;
}

.stock-adjust-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: -0.25rem 0 1.2rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-soft);
}

.stock-adjust-current > span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.stock-adjust-current > strong {
  font-size: 1.7rem;
  font-variant-numeric: tabular-nums;
}

.stock-adjust-current small {
  font-size: 0.8rem;
  font-weight: 650;
}

.stock-panel__summary {
  margin: -1.25rem -1.25rem 1.15rem;
  padding: 1.25rem;
  border-radius: var(--radius) var(--radius) 0 0;
  background: linear-gradient(145deg, var(--brand-900), var(--brand-700));
  color: #fff;
}

.stock-panel__summary .eyebrow,
.stock-panel__summary h2,
.stock-panel__summary p {
  color: #fff;
}

.stock-panel__summary .eyebrow {
  opacity: 0.72;
}

.stock-panel__summary h2 {
  margin-bottom: 0.5rem;
  font-size: 2rem;
}

.stock-panel__summary h2 small {
  font-size: 0.9rem;
  font-weight: 600;
  opacity: 0.75;
}

.stock-panel__summary p {
  margin-bottom: 0;
  font-size: 0.78rem;
  opacity: 0.78;
}

.stock-form {
  gap: 0.9rem;
}

.help-panel h2 {
  font-size: 1rem;
}

.help-panel > p {
  color: var(--muted);
  font-size: 0.82rem;
}

.meta-list {
  display: grid;
  gap: 0;
  margin: 1rem 0 0;
}

.meta-list > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.65rem 0;
  border-top: 1px solid #e8ebf0;
  font-size: 0.76rem;
}

.meta-list dt {
  color: var(--muted);
}

.meta-list dd {
  margin: 0;
  color: var(--ink-soft);
  font-weight: 700;
  text-align: right;
  overflow-wrap: anywhere;
}

.receipt-filter-bar {
  grid-template-columns: minmax(250px, 1.5fr) minmax(165px, 0.65fr) minmax(165px, 0.65fr) auto;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 650;
}

.pagination > div {
  display: flex;
  gap: 0.5rem;
}

.receipt-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-bottom: 1rem;
}

.receipt-summary-card,
.receipt-integrity {
  padding: 1.25rem;
}

.receipt-summary-card > h2 {
  overflow-wrap: anywhere;
}

.receipt-summary-card .meta-list,
.receipt-integrity .meta-list {
  margin-top: 0.8rem;
}

.receipt-lines {
  margin-bottom: 1rem;
}

.receipt-integrity {
  display: grid;
  grid-template-columns: minmax(180px, 0.45fr) minmax(0, 1fr);
  gap: 2rem;
}

.receipt-integrity .meta-list {
  margin: 0;
}

.archive-hash {
  max-width: 620px;
  word-break: break-all;
}

.form-alert {
  padding: 0.8rem 0.9rem;
  border: 1px solid #fac5bd;
  border-radius: 9px;
  background: var(--danger-soft);
  color: var(--danger);
  font-size: 0.82rem;
}

.form-alert--page {
  margin-bottom: 1rem;
}

.form-alert strong,
.form-alert p {
  margin: 0;
}

.form-alert p + p,
.form-alert strong + p {
  margin-top: 0.25rem;
}

.narrow-editor {
  display: grid;
  grid-template-columns: minmax(0, 720px) minmax(250px, 330px);
  align-items: start;
  gap: 1.25rem;
}

.auth-page {
  background:
    radial-gradient(circle at 12% 20%, rgb(211 160 57 / 15%), transparent 27rem),
    linear-gradient(135deg, #f7f1f2 0%, #f5f6f8 55%, #eef1f5 100%);
}

.auth-page .site-header {
  background: rgb(255 255 255 / 88%);
  backdrop-filter: blur(10px);
}

.auth-page .page-shell {
  display: grid;
  min-height: calc(100vh - 77px);
  place-items: center;
  padding-block: 2.5rem;
}

.auth-layout {
  display: grid;
  width: min(100%, 940px);
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, 0.9fr);
  align-items: center;
  gap: clamp(2rem, 7vw, 5.5rem);
}

.auth-intro h1 {
  max-width: 560px;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1.06;
}

.auth-intro > p:not(.eyebrow) {
  max-width: 540px;
  color: var(--ink-soft);
  font-size: 1.05rem;
}

.feature-list {
  display: grid;
  gap: 0.65rem;
  margin: 1.5rem 0 0;
  padding: 0;
  color: var(--ink-soft);
  font-size: 0.88rem;
  list-style: none;
}

.feature-list li {
  position: relative;
  padding-left: 1.65rem;
}

.feature-list li::before {
  position: absolute;
  top: 0.18rem;
  left: 0;
  display: grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 50%;
  background: var(--success-soft);
  color: var(--success);
  content: "✓";
  font-size: 0.68rem;
  font-weight: 900;
}

.auth-card {
  padding: clamp(1.4rem, 4vw, 2rem);
  border: 1px solid rgb(255 255 255 / 70%);
  border-radius: var(--radius-lg);
  background: rgb(255 255 255 / 94%);
  box-shadow: var(--shadow-md);
}

.auth-card__header {
  margin-bottom: 1.4rem;
}

.auth-card__header h2 {
  font-size: 1.65rem;
}

.auth-card__header p:last-child {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.auth-layout--setup {
  grid-template-columns: minmax(0, 1fr) minmax(370px, 0.92fr);
}

.auth-card--wide {
  display: grid;
  gap: 1rem;
}

.setup-steps {
  display: grid;
  max-width: 580px;
  gap: 0.75rem;
  margin: 1.5rem 0 0;
  padding-left: 1.35rem;
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.setup-steps li {
  padding-left: 0.25rem;
}

.setup-steps li::marker {
  color: var(--brand-700);
  font-weight: 800;
}

.otp-qr {
  width: min(100%, 288px);
  height: auto;
  margin-inline: auto;
  padding: 0.65rem;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
}

.manual-secret {
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-soft);
}

.manual-secret summary {
  padding: 0.7rem 0.85rem;
  color: var(--ink-soft);
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 720;
}

.manual-secret[open] summary {
  border-bottom: 1px solid var(--border);
}

.manual-secret p {
  margin: 0.75rem 0.85rem 0.35rem;
  color: var(--muted);
  font-size: 0.76rem;
}

.manual-secret code {
  display: block;
  margin: 0 0.85rem 0.85rem;
  padding: 0.65rem;
  overflow-wrap: anywhere;
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  user-select: all;
}

.recovery-codes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.recovery-codes code {
  display: block;
  padding: 0.62rem 0.7rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.025em;
  text-align: center;
  user-select: all;
}

.onboarding-page {
  background:
    radial-gradient(circle at 88% 15%, rgb(211 160 57 / 13%), transparent 28rem),
    var(--page);
}

.onboarding-page .page-shell {
  display: grid;
  min-height: calc(100vh - 142px);
  place-items: center;
}

.onboarding {
  display: grid;
  width: min(100%, 980px);
  grid-template-columns: minmax(0, 1fr) minmax(340px, 0.85fr);
  align-items: center;
  gap: clamp(2rem, 7vw, 5rem);
}

.onboarding__intro > p:not(.eyebrow) {
  max-width: 540px;
  color: var(--muted);
}

.onboarding__panel {
  padding: clamp(1.4rem, 4vw, 2rem);
  box-shadow: var(--shadow-md);
}

.onboarding-steps {
  display: grid;
  gap: 0.65rem;
  margin-top: 1.6rem;
}

.onboarding-steps span {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--muted);
  font-size: 0.84rem;
}

.onboarding-steps b {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  font-size: 0.72rem;
}

.onboarding-steps .is-current {
  color: var(--brand-800);
  font-weight: 750;
}

.onboarding-steps .is-current b {
  border-color: var(--brand-700);
  background: var(--brand-700);
  color: #fff;
}

.filter-bar--terminals {
  grid-template-columns: minmax(220px, 1fr) minmax(180px, 0.5fr) minmax(160px, 0.4fr) auto;
}

.filter-bar--stock {
  grid-template-columns: minmax(210px, 1fr) minmax(160px, 0.55fr) minmax(155px, 0.5fr) minmax(155px, 0.5fr) auto;
}

.terminal-cell {
  display: flex;
  min-width: 210px;
  align-items: center;
  gap: 0.75rem;
}

.terminal-cell__mark {
  display: grid;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 11px;
  background: var(--brand-50);
  color: var(--brand-700);
  font-size: 0.82rem;
  font-weight: 850;
}

.terminal-cell strong,
.terminal-cell small {
  display: block;
}

.terminal-cell small {
  margin-top: 0.15rem;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
  font-size: 0.75rem;
  overflow-wrap: anywhere;
}

.capability-list {
  display: flex;
  max-width: 210px;
  flex-wrap: wrap;
  gap: 0.32rem;
}

.capability-list > span:not(.muted-label) {
  padding: 0.22rem 0.5rem;
  border: 1px solid #d9e7df;
  border-radius: 999px;
  background: #f3faf6;
  color: var(--success);
  font-size: 0.7rem;
  font-weight: 720;
}

.muted-label {
  color: var(--muted);
  font-size: 0.78rem;
}

.connection-state {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 680;
  white-space: nowrap;
}

.connection-state::before {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--muted);
  content: "";
}

.connection-state--ready::before {
  background: var(--success);
  box-shadow: 0 0 0 3px var(--success-soft);
}

.connection-state--waiting::before {
  background: #b0790b;
  box-shadow: 0 0 0 3px var(--warning-soft);
}

.connection-state--muted {
  color: var(--muted);
}

.terminal-editor {
  grid-template-columns: minmax(0, 700px) minmax(290px, 360px);
}

.terminal-sidebar {
  display: grid;
  gap: 1rem;
}

.terminal-connection-card {
  padding: 1.25rem;
  border-top: 4px solid var(--brand-700);
}

.terminal-connection-card h2,
.terminal-connection-card > p:last-of-type {
  margin-bottom: 0.65rem;
}

.terminal-connection-card > p:not(.eyebrow),
.terminal-card-note {
  color: var(--muted);
  font-size: 0.8rem;
}

.terminal-card-note {
  margin: 0.7rem 0 0;
  line-height: 1.45;
}

.terminal-permissions {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.terminal-permissions legend {
  margin-bottom: 0.55rem;
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 720;
}

.connection-note {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  padding: 0.9rem;
  border: 1px solid #e8d8ba;
  border-radius: 10px;
  background: #fffaf0;
}

.connection-note__number {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font-size: 0.76rem;
  font-weight: 850;
}

.connection-note strong,
.connection-note p {
  display: block;
  margin: 0;
}

.connection-note p {
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.78rem;
}

.terminal-status-card__heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.terminal-status-card__heading h2 {
  margin-bottom: 0;
}

.terminal-state-form {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.terminal-state-form p {
  margin: 0.55rem 0 0;
  color: var(--muted);
  font-size: 0.75rem;
  text-align: center;
}

.compact-steps {
  display: grid;
  gap: 0.55rem;
  margin: 1rem 0 0;
  padding-left: 1.25rem;
  color: var(--ink-soft);
  font-size: 0.82rem;
}

.connection-layout {
  display: grid;
  grid-template-columns: minmax(360px, 0.94fr) minmax(340px, 0.78fr);
  align-items: start;
  gap: 1.25rem;
}

.qr-panel {
  padding: clamp(1.2rem, 3vw, 1.7rem);
}

.qr-panel__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.qr-panel__header h2,
.qr-panel__header p:last-child {
  margin-bottom: 0;
}

.qr-panel__header p:last-child {
  margin-top: 0.2rem;
  color: var(--muted);
  font-size: 0.8rem;
}

.status--waiting {
  border-color: #efdaa5;
  background: var(--warning-soft);
  color: #805b10;
  white-space: nowrap;
}

.qr-panel__code {
  display: grid;
  width: min(100%, 390px);
  margin: 1.25rem auto;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: #fff;
}

.qr-panel__code img {
  width: 100%;
  height: auto;
  border-radius: inherit;
}

.one-time-notice {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  padding: 0.85rem;
  border: 1px solid #efdaa5;
  border-radius: 10px;
  background: var(--warning-soft);
}

.one-time-notice > span {
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: #b0790b;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 900;
}

.one-time-notice p {
  margin: 0;
  color: #684a0b;
  font-size: 0.78rem;
}

.connection-guide {
  display: grid;
  gap: 1rem;
}

.connection-steps {
  padding: clamp(1.2rem, 3vw, 1.5rem);
}

.connection-steps ol {
  display: grid;
  gap: 1rem;
  margin: 1.25rem 0 1.4rem;
  padding: 0;
  list-style: none;
}

.connection-steps li {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
}

.connection-steps li > span {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 10px;
  background: var(--brand-50);
  color: var(--brand-700);
  font-size: 0.76rem;
  font-weight: 850;
}

.connection-steps strong,
.connection-steps small {
  display: block;
}

.connection-steps strong {
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.connection-steps small {
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.76rem;
}

.print-editor-heading {
  align-items: end;
}

.seller-template-switcher {
  display: grid;
  min-width: min(100%, 320px);
  gap: 0.35rem;
}

.seller-template-switcher label {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.seller-template-switcher select {
  width: 100%;
  min-height: 44px;
  padding: 0.65rem 2.2rem 0.65rem 0.8rem;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
}

.print-editor {
  display: grid;
  gap: 1rem;
  margin-top: 1.25rem;
}

.print-editor-tabs {
  display: grid;
  max-width: 980px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

.print-editor-tab {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 0 0.75rem;
  padding: 0.8rem 1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink-soft);
  text-align: left;
  cursor: pointer;
}

.print-editor-tab > span {
  display: grid;
  width: 38px;
  height: 38px;
  grid-row: 1 / 3;
  place-items: center;
  border-radius: 10px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 850;
}

.print-editor-tab strong,
.print-editor-tab small {
  display: block;
}

.print-editor-tab small {
  margin-top: 0.1rem;
  color: var(--muted);
  font-size: 0.73rem;
}

.print-editor-tab:hover,
.print-editor-tab.is-active {
  border-color: var(--brand-700);
  box-shadow: var(--shadow-sm);
}

.print-editor-tab.is-active {
  background: var(--brand-50);
  color: var(--brand-800);
}

.print-editor-tab.is-active > span {
  background: var(--brand-700);
  color: #fff;
}

.print-editor.is-enhanced .print-editor-panel:not(.is-active) {
  display: none;
}

.print-editor-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  align-items: start;
  gap: 1.25rem;
}

.print-editor-controls {
  display: grid;
  min-width: 0;
  gap: 1rem;
}

.locked-fields {
  padding: 0.9rem 1rem;
  border: 1px solid #d5e8dd;
  border-radius: 10px;
  background: #f3faf6;
}

.locked-fields span {
  display: inline-block;
  margin-bottom: 0.3rem;
  color: var(--success);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.055em;
  text-transform: uppercase;
}

.locked-fields p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.8rem;
}

.print-option-grid {
  margin-top: 1rem;
}

.template-tokens {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0 0 1rem;
}

.template-tokens span {
  padding: 0.28rem 0.55rem;
  border: 1px solid #eadcbf;
  border-radius: 7px;
  background: #fffaf0;
  color: #75530d;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 0.72rem;
  font-weight: 720;
}

.print-image-slots {
  display: grid;
  gap: 0.8rem;
}

.print-image-slot {
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-soft);
}

.print-image-slot__heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.8rem;
}

.print-image-slot__heading strong,
.print-image-slot__heading small {
  display: block;
}

.print-image-slot__heading strong {
  font-size: 0.88rem;
}

.print-image-slot__heading small {
  margin-top: 0.12rem;
  color: var(--muted);
  font-size: 0.7rem;
}

.print-image-slot__body {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  align-items: start;
  gap: 0.9rem;
}

.print-image-upload {
  position: relative;
  display: grid;
  min-height: 116px;
  place-items: center;
  align-content: center;
  gap: 0.45rem;
  padding: 0.65rem;
  border: 1px dashed var(--border-strong);
  border-radius: 10px;
  background: var(--surface);
  text-align: center;
  overflow: hidden;
}

.print-image-upload > span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  background: var(--brand-50);
  color: var(--brand-700);
  font-size: 1.25rem;
}

.print-image-upload img {
  max-height: 72px;
  object-fit: contain;
  image-rendering: pixelated;
}

.print-image-upload label {
  color: var(--brand-700);
  font-size: 0.72rem;
  font-weight: 760;
  cursor: pointer;
}

.print-image-upload input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.print-image-settings {
  display: grid;
  grid-template-columns: repeat(2, minmax(120px, 1fr));
  gap: 0.65rem;
}

.print-image-settings .field > label {
  font-size: 0.72rem;
}

.print-image-settings input,
.print-image-settings select {
  min-height: 40px;
  padding: 0.5rem 0.6rem;
}

.print-image-settings .field-help {
  font-size: 0.66rem;
}

.print-image-remove {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.75rem;
  color: var(--danger);
  font-size: 0.73rem;
  font-weight: 700;
}

.print-preview-column {
  position: sticky;
  top: 1rem;
  min-width: 0;
  padding: 1rem;
  border: 1px solid #30353d;
  border-radius: 16px;
  background: #20242a;
  box-shadow: var(--shadow-md);
}

.print-preview-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
  color: #f4f6f8;
}

.print-preview-toolbar > div {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.print-preview-toolbar small {
  color: #aeb6c2;
  font-size: 0.7rem;
}

.preview-editor-hint {
  display: grid;
  gap: 0.18rem;
  margin: -0.25rem 0 0.8rem;
  color: #aeb6c2;
  font-size: 0.68rem;
  line-height: 1.35;
}

.preview-editor-hint strong {
  color: #76d9ac;
  font-size: 0.7rem;
}

.preview-editor-hint b {
  color: #76d9ac;
  font-size: 0.85rem;
}

.preview-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #40c48a;
  box-shadow: 0 0 0 4px rgb(64 196 138 / 13%);
}

.thermal-paper {
  position: relative;
  width: min(100%, 352px);
  min-height: 570px;
  margin-inline: auto;
  padding: 25px 22px 34px;
  background: #fffef8;
  box-shadow: 0 14px 30px rgb(0 0 0 / 28%);
  color: #050505;
  font-family: "Courier New", ui-monospace, monospace;
  font-size: 16px;
  line-height: 1.3;
  overflow-wrap: break-word;
  word-break: normal;
}

.thermal-paper::after {
  position: absolute;
  right: 0;
  bottom: -8px;
  left: 0;
  height: 9px;
  background: linear-gradient(135deg, #fffef8 5px, transparent 0) 0 0 / 10px 10px repeat-x;
  content: "";
}

.thermal-paper [hidden] {
  display: none !important;
}

.paper-heading {
  margin-bottom: 0.4rem;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.08;
  text-align: center;
  text-transform: uppercase;
}

.paper-document-type {
  margin-bottom: 0.35rem;
  font-size: 10px;
  font-weight: 800;
  text-align: center;
}

.paper-center {
  text-align: center;
  white-space: pre-line;
}

.paper-small {
  font-size: 12px;
}

.paper-seller,
.paper-ticket-title {
  margin-top: 0.28rem;
  font-weight: 900;
}

.paper-ticket-title {
  font-size: 15px;
}

.paper-intro,
.paper-footer {
  margin: 0.55rem 0;
  white-space: pre-line;
}

.paper-divider {
  height: 1px;
  margin: 0.65rem 0;
  border-top: 1px dashed #111;
}

.paper-divider.is-bold {
  height: 3px;
  border-top: 3px solid #111;
}

.paper-row,
.paper-total {
  display: flex;
  justify-content: space-between;
  gap: 0.7rem;
}

.paper-row strong {
  text-align: right;
}

.paper-items {
  display: grid;
  gap: 0.55rem;
}

.paper-item strong,
.paper-item span {
  display: block;
}

.paper-item span {
  margin-top: 0.08rem;
  font-size: 10px;
}

.paper-items.is-compact .paper-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
}

.paper-items.is-compact .paper-item strong {
  max-width: 58%;
}

.paper-items.is-compact .paper-item span {
  text-align: right;
  white-space: pre;
}

.paper-total {
  align-items: baseline;
  font-size: 17px;
}

.paper-vat {
  margin-top: 0.5rem;
}

.paper-image {
  position: relative;
  width: 100%;
  margin: 0.5rem 0;
}

.paper-image:empty {
  display: none;
}

.paper-image img {
  display: block;
  max-width: 100%;
  height: auto;
  filter: grayscale(1) contrast(1.35);
  image-rendering: pixelated;
}

.paper-image img.is-threshold {
  filter: grayscale(1) contrast(3);
}

.paper-image img[data-alignment="left"] {
  margin-right: auto;
}

.paper-image img[data-alignment="center"] {
  margin-inline: auto;
}

.paper-image img[data-alignment="right"] {
  margin-left: auto;
}

.thermal-paper--price-label {
  width: min(100%, 334px);
  min-height: 330px;
  padding-inline: 18px;
}

.paper-label-name {
  margin-block: 0.35rem;
  font-size: 19px;
  font-weight: 900;
  line-height: 1.12;
}

.paper-label-original {
  margin-top: 0.4rem;
  font-size: 14px;
  text-decoration: line-through;
}

.paper-label-badge {
  margin-top: 0.25rem;
  font-size: 17px;
  font-weight: 900;
}

.paper-label-price {
  margin-top: 0.15rem;
  font-size: 27px;
  font-weight: 900;
  line-height: 1.05;
}

.paper-image-resize {
  position: absolute;
  right: -6px;
  bottom: -6px;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #007d69;
  box-shadow: 0 1px 5px rgb(0 0 0 / 32%);
  cursor: nwse-resize;
  touch-action: none;
}

.paper-image-resize::before {
  color: #fff;
  content: "↘";
  font-size: 12px;
  font-weight: 900;
}

.paper-qr {
  width: 176px;
  margin: 0.65rem auto 0.35rem;
  image-rendering: pixelated;
}

.paper-qr[data-size="small"] { width: 132px; }
.paper-qr[data-size="large"] { width: 220px; }

.paper-barcode {
  display: flex;
  width: 190px;
  height: 45px;
  align-items: stretch;
  justify-content: center;
  gap: 2px;
  margin: 0.7rem auto 0.2rem;
}

.paper-barcode i {
  width: 4px;
  background: #000;
}

.paper-barcode i:nth-child(3n) { width: 2px; }
.paper-barcode i:nth-child(4n) { width: 7px; }

.paper-code {
  font-weight: 800;
}

.preview-note {
  max-width: 330px;
  margin: 1rem auto 0;
  color: #aeb6c2;
  font-size: 0.68rem;
  line-height: 1.45;
  text-align: center;
}

.print-editor > .editor-actions {
  position: sticky;
  z-index: 4;
  bottom: 0;
  align-items: center;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: 12px 12px 0 0;
  background: rgb(255 255 255 / 94%);
  box-shadow: 0 -8px 24px rgb(16 24 40 / 8%);
  backdrop-filter: blur(8px);
}

.print-editor > .editor-actions > div {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.print-editor > .editor-actions > div::before {
  color: var(--muted);
  content: "Změny se projeví po synchronizaci";
  font-size: 0.72rem;
}

.print-section-layout {
  display: grid;
  gap: 0.65rem;
}

.print-block-card {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 11px;
  background: var(--surface);
  transition: border-color 140ms ease, opacity 140ms ease;
}

.print-block-card:hover {
  border-color: var(--brand-700);
}

.print-block-card.is-selected {
  border-color: var(--brand-700);
  box-shadow: 0 0 0 3px rgb(0 93 79 / 12%);
}

.print-block-card.is-muted {
  opacity: 0.62;
}

.print-block-heading {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.2rem 0.7rem;
  padding: 0.62rem 0.72rem;
  background: var(--surface-soft);
}

.print-block-heading > strong {
  align-self: end;
}

.print-block-heading > small {
  grid-column: 2;
  color: var(--muted);
  font-size: 0.68rem;
}

.print-block-order {
  display: grid;
  width: 34px;
  height: 34px;
  grid-row: 1 / 3;
  place-items: center;
  border-radius: 9px;
  background: var(--brand-700);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
}

.print-block-moves {
  display: flex;
  grid-column: 3;
  grid-row: 1 / 3;
  gap: 0.35rem;
}

.print-block-moves button {
  width: 35px;
  height: 35px;
  padding: 0;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: #fff;
  color: var(--brand-800);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.print-block-moves button:disabled {
  opacity: 0.35;
  cursor: default;
}

.print-block-controls {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.6rem;
  padding: 0.72rem;
}

.print-block-control {
  display: grid;
  min-width: 0;
  gap: 0.28rem;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
}

.print-block-control select {
  min-width: 0;
  width: 100%;
}

.print-block-control input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin: 0.55rem 0;
  accent-color: var(--brand-700);
}

.thermal-paper .layout-align-left {
  justify-content: flex-start;
  text-align: left;
}

.thermal-paper .layout-align-center {
  justify-content: center;
  text-align: center;
}

.thermal-paper .layout-align-right {
  justify-content: flex-end;
  text-align: right;
}

.thermal-paper .layout-size-small { font-size: 12px; }
.thermal-paper .layout-size-normal { font-size: 16px; }
.thermal-paper .layout-size-large { font-size: 19px; }
.thermal-paper .layout-size-extra-large { font-size: 21px; }
.thermal-paper .layout-regular { font-weight: 400; }
.thermal-paper .layout-bold { font-weight: 900; }

.thermal-paper .print-section-divider {
  flex: none;
}

.thermal-paper.is-direct-editor [data-preview-section]:not([hidden]) {
  border-radius: 3px;
  cursor: grab;
  outline: 1px solid transparent;
  outline-offset: 3px;
  user-select: none;
  transition: opacity 120ms ease, outline-color 120ms ease, box-shadow 120ms ease;
}

.thermal-paper.is-direct-editor [data-preview-section]:not([hidden]):hover {
  outline-color: rgb(0 93 79 / 48%);
}

.thermal-paper.is-direct-editor [data-preview-section]:not([hidden]):focus-visible,
.thermal-paper.is-direct-editor [data-preview-section].is-selected {
  outline: 2px solid #007d69;
  outline-offset: 3px;
}

.thermal-paper.is-direct-editor [data-preview-section].is-dragging {
  opacity: 0.32;
  cursor: grabbing;
}

.thermal-paper.is-direct-editor [data-preview-section].is-drop-before {
  box-shadow: 0 -4px 0 #e55d35;
}

.thermal-paper.is-direct-editor [data-preview-section].is-drop-after {
  box-shadow: 0 4px 0 #e55d35;
}

.thermal-paper.is-direct-editor.is-drop-at-end {
  box-shadow: inset 0 -5px 0 #e55d35, 0 14px 30px rgb(0 0 0 / 28%);
}

@media (max-width: 1050px) {
  .print-block-controls {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .print-editor-workspace {
    grid-template-columns: minmax(0, 1fr) 340px;
  }

  .print-image-slot__body {
    grid-template-columns: minmax(120px, 0.7fr) minmax(0, 1.3fr);
  }

  .print-image-settings {
    grid-template-columns: minmax(0, 1fr);
  }
  .receipt-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .receipt-summary-card:last-child {
    grid-column: 1 / -1;
  }

  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .editor-layout {
    grid-template-columns: minmax(0, 1fr) 290px;
  }

  .code-row {
    grid-template-columns: minmax(160px, 1.4fr) minmax(100px, 0.8fr) minmax(140px, 1fr);
  }

  .filter-bar {
    grid-template-columns: minmax(220px, 1.2fr) repeat(2, minmax(150px, 0.8fr));
  }

  .filter-bar__actions {
    grid-column: 1 / -1;
  }

  .code-row .check-control--inline {
    justify-self: start;
  }
}

@media (max-width: 860px) {
  .print-editor-workspace {
    grid-template-columns: minmax(0, 1fr);
  }

  .print-preview-column {
    position: static;
    grid-row: 1;
  }

  .print-editor-controls {
    grid-row: 2;
  }

  .editor-layout,
  .narrow-editor,
  .connection-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .connection-guide {
    grid-row: 1;
  }

  .qr-panel {
    grid-row: 2;
  }

  .editor-sidebar {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .auth-layout,
  .onboarding {
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
  }

  .dashboard-onboarding {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
  }

  .auth-intro,
  .onboarding__intro {
    text-align: center;
  }

  .auth-intro h1,
  .auth-intro > p,
  .onboarding__intro > p {
    margin-right: auto;
    margin-left: auto;
  }

  .feature-list,
  .onboarding-steps {
    width: fit-content;
    margin-right: auto;
    margin-left: auto;
    text-align: left;
  }
}

@media (max-width: 680px) {
  .print-block-controls {
    grid-template-columns: minmax(0, 1fr);
  }

  .print-block-heading {
    grid-template-columns: 38px minmax(0, 1fr);
  }

  .print-block-moves {
    grid-column: 2;
    grid-row: 3;
    margin-top: 0.35rem;
  }

  .print-editor > .editor-actions,
  .print-editor > .editor-actions > div {
    align-items: stretch;
    flex-direction: column;
  }

  .print-image-slot__body,
  .print-image-settings {
    grid-template-columns: minmax(0, 1fr);
  }

  .print-editor-tabs {
    grid-template-columns: minmax(0, 1fr);
  }

  .print-preview-column {
    padding: 0.65rem;
    border-radius: 12px;
  }

  .thermal-paper {
    padding-right: 16px;
    padding-left: 16px;
  }

  .receipt-summary-grid,
  .receipt-integrity {
    grid-template-columns: minmax(0, 1fr);
  }

  .receipt-summary-card:last-child {
    grid-column: auto;
  }

  .pagination {
    align-items: stretch;
    flex-direction: column;
    padding: 1rem;
  }

  .pagination > div,
  .pagination .button {
    width: 100%;
  }

  .catalog-scope-note {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.2rem;
  }

  .field-label-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.25rem;
  }

  .site-header__inner,
  .primary-nav__inner,
  .site-footer__inner,
  .page-shell,
  .flash-messages {
    width: min(calc(100% - 1.25rem), var(--content-width));
  }

  .site-header__inner {
    min-height: 68px;
  }

  .brand__mark {
    width: 38px;
    height: 38px;
  }

  .brand__text strong {
    font-size: 0.9rem;
  }

  .brand__text small,
  .organization-label {
    display: none;
  }

  .primary-nav__inner {
    gap: 1.4rem;
  }

  .organization-switcher {
    padding-left: 0.35rem;
  }

  .organization-switcher select {
    min-width: 145px;
    max-width: 190px;
  }

  .primary-nav a {
    min-height: 46px;
  }

  .page-shell {
    padding-block: 1.5rem 3rem;
  }

  .page-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 1rem;
  }

  .qr-panel__header {
    align-items: flex-start;
    flex-direction: column;
  }

  .qr-panel__header .status {
    align-self: flex-start;
  }

  .page-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .page-actions .button {
    flex: 1 1 auto;
  }

  .metric-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .filter-bar {
    grid-template-columns: minmax(0, 1fr);
    padding: 1rem;
  }

  .filter-bar__actions {
    grid-column: auto;
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .filter-bar__actions .button {
    width: 100%;
  }

  .metric-card {
    min-height: 142px;
  }

  .panel__header {
    align-items: flex-start;
    padding: 1.1rem;
  }

  .table-scroll {
    overflow: visible;
  }

  .data-table,
  .data-table tbody,
  .data-table tr,
  .data-table td {
    display: block;
    width: 100%;
  }

  .data-table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
  }

  .data-table tbody {
    padding: 0.65rem;
  }

  .data-table tbody tr {
    padding: 0.45rem 0.8rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
  }

  .data-table tbody tr + tr {
    margin-top: 0.65rem;
  }

  .data-table td,
  .data-table th:first-child,
  .data-table td:first-child,
  .data-table th:last-child,
  .data-table td:last-child {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.55rem 0;
    border-bottom: 1px solid #edf0f4;
    text-align: right;
  }

  .data-table td::before {
    flex: 0 0 auto;
    color: var(--muted);
    content: attr(data-label);
    font-size: 0.68rem;
    font-weight: 780;
    letter-spacing: 0.04em;
    text-transform: uppercase;
  }

  .data-table td:first-child {
    align-items: flex-start;
    flex-direction: column;
    text-align: left;
  }

  .data-table td:first-child::before {
    margin-bottom: -0.2rem;
  }

  .data-table td:last-child {
    padding-top: 0.75rem;
    border-bottom: 0;
  }

  .data-table td:last-child::before {
    display: none;
  }

  .data-table .numeric,
  .data-table .table-action {
    text-align: right;
  }

  .data-table .table-action .button {
    width: 100%;
  }

  .product-cell {
    width: 100%;
    min-width: 0;
  }

  .form-grid--two,
  .check-grid,
  .editor-sidebar {
    grid-template-columns: minmax(0, 1fr);
  }

  .form-section {
    padding: 1rem;
  }

  .form-section__header,
  .form-section__header--actions {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  .form-section__header--actions .button {
    grid-column: 1 / -1;
    justify-self: stretch;
  }

  .section-number {
    width: 32px;
    height: 32px;
  }

  .thumbnail-editor {
    grid-template-columns: 88px minmax(0, 1fr);
  }

  .thumbnail-preview {
    width: 88px;
  }

  .code-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .code-field--value {
    grid-column: 1 / -1;
  }

  .check-control--inline {
    width: 100%;
    justify-self: stretch !important;
  }

  .editor-actions {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .editor-actions .button {
    width: 100%;
  }

  .site-footer__inner {
    align-items: flex-start;
    justify-content: center;
    flex-direction: column;
    padding-block: 1rem;
  }

  .auth-page .page-shell,
  .onboarding-page .page-shell {
    display: block;
    padding-block: 1.5rem;
  }

  .auth-intro,
  .onboarding__intro {
    text-align: left;
  }

  .setup-steps {
    margin-left: 0;
  }

  .recovery-codes {
    grid-template-columns: minmax(0, 1fr);
  }

  .auth-intro h1 {
    font-size: 2.25rem;
  }

  .feature-list,
  .onboarding-steps {
    width: auto;
    margin-left: 0;
  }
}

@media (max-width: 430px) {
  .brand__text small {
    display: none;
  }

  .logout-form .button {
    min-height: 36px;
    padding-inline: 0.62rem;
  }

  .thumbnail-editor {
    grid-template-columns: minmax(0, 1fr);
  }

  .thumbnail-preview {
    width: 100%;
    max-width: 160px;
  }

  .code-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .code-field--value {
    grid-column: auto;
  }

  .empty-state__actions,
  .empty-state__actions .button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

.movement-delta {
  white-space: nowrap;
}

.movement-delta--positive {
  color: var(--success-strong, #166534);
}

.movement-delta--negative {
  color: var(--danger, #b42318);
}

.danger-confirm {
  max-width: 780px;
}

.location-map-panel {
  overflow: hidden;
}

.location-map {
  width: 100%;
  min-height: 430px;
  border-top: 1px solid var(--border, #d9e0e5);
  background: #e8eef0;
  z-index: 0;
}

.location-map--detail {
  min-height: 560px;
}

.coordinate {
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
  white-space: nowrap;
}

.metric-card__value--date {
  font-size: clamp(1rem, 1.8vw, 1.35rem) !important;
  line-height: 1.3;
}

@media (max-width: 720px) {
  .account-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .organization-label {
    display: none;
  }

  .location-map,
  .location-map--detail {
    min-height: 360px;
  }
}

@media print {
  .site-header,
  .site-footer,
  .page-actions,
  .editor-actions,
  .button {
    display: none !important;
  }

  body,
  .page-shell {
    background: #fff;
  }

  .page-shell {
    width: 100%;
    padding: 0;
  }

  .panel,
  .metric-card {
    box-shadow: none;
  }

  .recovery-codes {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
