@keyframes simIn {
  from {
    opacity: 0;
    translate: 0 12px;
  }
  to {
    opacity: 1;
    translate: 0 0;
  }
}
@keyframes simSpin {
  to {
    rotate: 360deg;
  }
}
@keyframes stampIn {
  from {
    opacity: 0;
    scale: 2.2;
  }
  to {
    opacity: 1;
    scale: 1;
  }
}
@keyframes guidePulse {
  0% {
    box-shadow: 0 0 0 0 rgba(255, 75, 66, 0.65);
  }
  70% {
    box-shadow: 0 0 0 12px rgba(255, 75, 66, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(255, 75, 66, 0);
  }
}
@keyframes coachBob {
  0%, 100% {
    translate: -50% 0;
  }
  50% {
    translate: -50% 5px;
  }
}
@keyframes rowFresh {
  from {
    background: rgba(16, 185, 129, 0.22);
  }
  to {
    background: transparent;
  }
}
@keyframes cardFlash {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6);
  }
  100% {
    box-shadow: 0 0 0 14px rgba(16, 185, 129, 0);
  }
}
.section-simulator {
  position: relative;
  overflow: hidden;
  padding: var(--section-y) 0;
  background: radial-gradient(45% 50% at 10% 20%, rgba(255, 75, 66, 0.12), transparent 70%), var(--ink);
  border-top: 1px solid var(--line);
  color: #ffffff;
}

.hero-sim-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: -1.1rem 0 1.75rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.75);
}
.hero-sim-link i {
  color: #ff4b42;
  font-size: 1.1rem;
}
.hero-sim-link:hover {
  color: #ffffff;
  opacity: 1;
}

.sim {
  display: grid;
  gap: clamp(1rem, 0.8333333333rem + 0.7407407407vw, 1.5rem);
  align-items: start;
}
@media (min-width: 1200px) {
  .sim {
    grid-template-columns: minmax(0, 1fr) 300px;
  }
}

.sim-frame {
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 60px 120px -40px rgba(0, 0, 0, 0.9), 0 30px 90px -60px rgba(255, 75, 66, 0.6);
}
.sim-frame__bar {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.65rem 1rem;
  background: #11161d;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.78rem;
}
.sim-frame__dots {
  display: flex;
  gap: 6px;
}
.sim-frame__dots i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ff5f57;
}
.sim-frame__dots i:nth-child(2) {
  background: #febc2e;
}
.sim-frame__dots i:nth-child(3) {
  background: #28c840;
}
.sim-frame__url {
  flex: 1;
  min-width: 0;
  padding: 0.3rem 0.8rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.55);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sim-frame__url i {
  color: #3ddc63;
  margin-right: 0.3rem;
}
.sim-frame__timer {
  font-family: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  color: #ffffff;
  padding: 0.25rem 0.6rem;
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.06);
  white-space: nowrap;
}
@media (max-width: 575.98px) {
  .sim-frame__url {
    display: none;
  }
}

.sim-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: 50px;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #ff8a80;
  background: rgba(255, 75, 66, 0.12);
  border: 1px solid rgba(255, 75, 66, 0.3);
  white-space: nowrap;
}
@media (max-width: 575.98px) {
  .sim-badge {
    margin-left: auto;
  }
}

.erp {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  height: clamp(560px, 78vh, 700px);
  background: #111827;
  color: #e5e7eb;
  font-size: 0.8125rem;
  line-height: 1.4;
  container-type: inline-size;
  container-name: erpf;
}
@media (min-width: 992px) {
  .erp {
    grid-template-columns: 190px minmax(0, 1fr);
  }
}
.erp button {
  font-family: inherit;
  color: inherit;
}
.erp__side {
  display: none;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem 0.65rem;
  background: #21262d;
  border-right: 1px solid #30363d;
  overflow: hidden;
}
@media (min-width: 992px) {
  .erp__side {
    display: flex;
  }
}
.erp__side nav {
  display: grid;
  gap: 2px;
}
.erp__side nav span {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.65rem;
  border-radius: 6px;
  font-size: 0.78rem;
  color: #c2c7d0;
  white-space: nowrap;
}
.erp__side nav span i {
  width: 1rem;
  color: #9ca3af;
}
.erp__side nav span.is-active {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-weight: 600;
}
.erp__side nav span.is-active i {
  color: #0ea5e9;
}
.erp__brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 0.5rem;
  font-family: "Poppins", sans-serif;
  font-size: 1.05rem;
  color: #ffffff;
}
.erp__brand b {
  color: #ff4b42;
  font-weight: 700;
}
.erp__body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
}
.erp__nav {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  height: 48px;
  padding: 0 1rem;
  background: #21262d;
  border-bottom: 1px solid #30363d;
  color: #c2c7d0;
  font-size: 0.78rem;
}
.erp__nav > i {
  font-size: 1.25rem;
}
.erp__nav b {
  color: #ffffff;
  font-weight: 600;
}
.erp__nav .bi-chevron-right {
  font-size: 0.6rem;
  margin: 0 0.2rem;
}
.erp__crumb {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}
.erp__nav-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  font-size: 1rem;
}
.erp__avatar {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #0369a1;
  color: #ffffff;
  font-size: 0.62rem;
  font-weight: 700;
}
.erp__main {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: clamp(0.75rem, 0.5rem + 1.1111111111vw, 1.5rem);
  scrollbar-width: thin;
  container-type: inline-size;
  container-name: erp;
}

.erp-view {
  display: none;
}
.erp-view.is-active {
  display: block;
  animation: simIn 0.4s var(--ease-out);
}

.erp-muted {
  color: #9ca3af;
}

.erp-mono {
  font-family: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.92em;
}

.erp-ico-sky {
  color: #0ea5e9;
}

.erp-ico-green {
  color: #10b981;
}

.erp-spin {
  display: inline-block;
  animation: simSpin 0.9s linear infinite;
}

.erp-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  margin-bottom: 1rem;
}
.erp-head h3 {
  margin: 0 0 0.2rem;
  color: #ffffff;
  font-size: clamp(1.1rem, 1rem + 0.4444444444vw, 1.4rem);
  font-weight: 700;
}
.erp-head p {
  margin: 0;
  color: #9ca3af;
  font-size: 0.8rem;
}

.erp-back {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid #374151;
  background: #374151;
  color: #ffffff;
  transition: background-color 0.2s ease;
}
.erp-back:hover {
  background: #4b5563;
}

.erp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  height: 36px;
  padding: 0 0.95rem;
  border-radius: 6px;
  border: 1px solid transparent;
  background: transparent;
  font-size: 0.8rem;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, opacity 0.2s ease, color 0.2s ease;
}
.erp-btn--sm {
  height: 32px;
  padding: 0 0.75rem;
  font-size: 0.75rem;
}
.erp-btn--xs {
  height: 26px;
  padding: 0 0.55rem;
  font-size: 0.68rem;
  gap: 0.3rem;
}
.erp-btn--success-soft {
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.3);
  background: rgba(16, 185, 129, 0.1);
}
.erp-btn--success-soft:hover:not(:disabled) {
  background: rgba(16, 185, 129, 0.2);
}
.erp-btn--success {
  color: #ffffff;
  background: #047857;
  border-color: #047857;
  font-weight: 600;
}
.erp-btn--success:hover:not(:disabled) {
  background: #065f46;
}
.erp-btn--primary {
  color: #ffffff;
  background: #0369a1;
  border-color: #0369a1;
  font-weight: 600;
}
.erp-btn--primary:hover:not(:disabled) {
  background: #075985;
}
.erp-btn--primary-soft {
  color: #7dd3fc;
  border-color: rgba(14, 165, 233, 0.3);
  background: rgba(14, 165, 233, 0.1);
}
.erp-btn--primary-soft:hover:not(:disabled) {
  background: rgba(14, 165, 233, 0.2);
}
.erp-btn--danger-soft {
  color: #f87171;
  border-color: rgba(239, 68, 68, 0.3);
  background: rgba(239, 68, 68, 0.1);
}
.erp-btn--danger-soft:hover:not(:disabled) {
  background: rgba(239, 68, 68, 0.2);
}
.erp-btn--o-green {
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.45);
  background: rgba(16, 185, 129, 0.05);
}
.erp-btn--o-green:hover:not(:disabled) {
  background: rgba(16, 185, 129, 0.15);
}
.erp-btn--o-sky {
  color: #7dd3fc;
  border-color: rgba(14, 165, 233, 0.45);
  background: rgba(14, 165, 233, 0.05);
}
.erp-btn--o-sky:hover:not(:disabled) {
  background: rgba(14, 165, 233, 0.15);
}
.erp-btn--o-amber {
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.05);
}
.erp-btn--o-amber:hover:not(:disabled) {
  background: rgba(245, 158, 11, 0.15);
}
.erp-btn--o-gray {
  color: #d1d5db;
  border-color: #4b5563;
  background: rgba(156, 163, 175, 0.06);
}
.erp-btn--o-gray:hover:not(:disabled) {
  background: rgba(156, 163, 175, 0.16);
}
.erp-btn--transmit {
  color: #ffffff;
  font-weight: 600;
  background: linear-gradient(135deg, #0369a1, #075985);
  border-color: transparent;
}
.erp-btn--transmit:hover:not(:disabled) {
  background: linear-gradient(135deg, #075985, #0c4a6e);
}
.erp-btn:disabled, .erp-btn.is-locked {
  opacity: 0.5;
  cursor: not-allowed;
}

.erp-pulse {
  position: relative;
}
.erp-pulse::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  pointer-events: none;
  border: 1px solid rgba(16, 185, 129, 0.6);
  animation: erpPing 1.4s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes erpPing {
  0% {
    opacity: 0.8;
    scale: 1;
  }
  75%, 100% {
    opacity: 0;
    scale: 1.12 1.5;
  }
}
.erp-iconbtn {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 6px;
  border: 1px solid transparent;
  background: transparent;
  color: #9ca3af;
}
.erp-iconbtn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.erp-status, .erp-origin, .erp-model {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.12rem 0.5rem;
  border-radius: 50px;
  font-size: 0.625rem;
  font-weight: 600;
  font-style: normal;
  line-height: 1.5;
  white-space: nowrap;
  color: var(--c);
  background: color-mix(in srgb, var(--c) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--c) 30%, transparent);
}

.erp-status {
  --c: #9ca3af;
}
.erp-status.is-ok {
  --c: #34d399;
}
.erp-status.is-billed {
  --c: #d19a5c;
}
.erp-status.is-cancel {
  --c: #f87171;
}

.erp-origin {
  --c: #7dd3fc;
  font-size: 0.5625rem;
  padding: 0 0.4rem;
  margin-left: 0.3rem;
  vertical-align: 1px;
}
.erp-origin.is-ecom {
  --c: #a78bfa;
}

.erp-model {
  --c: #7dd3fc;
  font-size: 0.5625rem;
  padding: 0 0.4rem;
}
.erp-model.is-nfce {
  --c: #a78bfa;
}

.erp-frame {
  padding: 1rem;
  border-radius: 8px;
  background: #151b26;
  border: 1px solid #0d1117;
}
@container erp (max-width: 560px) {
  .erp-frame {
    padding: 0.5rem;
  }
}

.erp-listcard {
  border-radius: 8px;
  background: #1c2431;
  border: 1px solid #2d3646;
  overflow: hidden;
}

.erp-toolbar {
  padding: 0.65rem;
  display: grid;
  gap: 0.55rem;
  background: #151b26;
  border-bottom: 1px solid #2d3646;
}

.erp-search {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 38px;
  padding: 0 0.4rem 0 0.75rem;
  border-radius: 6px;
  background: #111827;
  border: 1px solid #374151;
  color: #9ca3af;
}
.erp-search > i:first-child {
  color: #9ca3af;
}
.erp-search > span {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.78rem;
}
.erp-search--input {
  margin: 0 0 0.75rem;
  cursor: text;
}
.erp-search--input:focus-within {
  border-color: #0ea5e9;
  box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.25);
}
.erp-search--input input {
  flex: 1;
  min-width: 0;
  height: 36px;
  border: none;
  outline: none;
  background: transparent;
  color: #ffffff;
  font-size: 0.8rem;
}
.erp-search--input input::placeholder {
  color: #9ca3af;
}

.erp-filters {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.erp-filters > i {
  color: #9ca3af;
}

.erp-select {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  height: 28px;
  padding: 0 0.55rem;
  border-radius: 6px;
  border: 1px solid #374151;
  background: #111827;
  color: #d1d5db;
  font-size: 0.72rem;
  white-space: nowrap;
}
.erp-select i {
  font-size: 0.65rem;
}
.erp-select:hover {
  border-color: #4b5563;
}
.erp-select--period {
  margin-left: auto;
}
.erp-select--xs {
  height: 24px;
  font-size: 0.68rem;
  padding: 0 0.45rem;
}

.erp-table {
  overflow-x: auto;
}

.erp-table__head, .erp-trow {
  display: grid;
  grid-template-columns: minmax(0, 2fr) 1.1fr 1.3fr 1.1fr 1.2fr 0.9fr 1fr;
  gap: 0.75rem;
  align-items: center;
  padding: 0 1rem;
}
.erp-table__head .c, .erp-trow .c {
  text-align: center;
  justify-self: center;
}
.erp-table__head .r, .erp-trow .r {
  text-align: right;
  justify-self: end;
}
@container erp (max-width: 900px) {
  .erp-table__head, .erp-trow {
    grid-template-columns: minmax(0, 2fr) 1.1fr 1.1fr 1.2fr 0.9fr 1fr;
  }
  .erp-table__head .lg, .erp-trow .lg {
    display: none;
  }
}
@container erp (max-width: 720px) {
  .erp-table__head, .erp-trow {
    grid-template-columns: minmax(0, 2fr) 1.1fr 0.9fr 1fr;
  }
  .erp-table__head .md, .erp-trow .md {
    display: none;
  }
}
@container erp (max-width: 560px) {
  .erp-table__head, .erp-trow {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  .erp-table__head .sm, .erp-trow .sm {
    display: none;
  }
}

.erp-table__head {
  position: sticky;
  top: 0;
  z-index: 2;
  min-height: 34px;
  background: #111827;
  border-bottom: 1px solid #2d3646;
  color: #9ca3af;
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
@container erp (max-width: 560px) {
  .erp-table__head .c {
    display: none;
  }
}

.erp-trow {
  min-height: 58px;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  background: #1c2431;
  border-bottom: 1px solid #2d3646;
  border-left: 3px solid transparent;
  font-size: 0.75rem;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}
.erp-trow:hover {
  background: #232c3d;
  border-left-color: #0ea5e9;
}
.erp-trow:hover .erp-trow__ico {
  color: #0ea5e9;
}
.erp-trow.is-own {
  cursor: pointer;
  background: rgba(14, 165, 233, 0.07);
}
.erp-trow.is-own:hover {
  background: rgba(14, 165, 233, 0.14);
}
.erp-trow small {
  color: #9ca3af;
  font-size: 0.6875rem;
}
@container erp (max-width: 560px) {
  .erp-trow {
    row-gap: 0.25rem;
  }
  .erp-trow .c {
    grid-column: 1;
    grid-row: 2;
    justify-self: start;
    padding-left: 2.6rem;
  }
  .erp-trow .r {
    grid-column: 2;
    grid-row: 1;
  }
}
.erp-trow__main {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}
.erp-trow__main > span:last-child {
  min-width: 0;
  display: block;
}
.erp-trow__main b {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
}
.erp-trow__main small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.erp-trow__ico {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: #111827;
  border: 1px solid #2d3646;
  color: #9ca3af;
  transition: color 0.15s ease;
}
.erp-trow__value {
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
}

.erp-table__foot {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.65rem 1rem;
  background: #151b26;
  border-top: 1px solid #2d3646;
  color: #9ca3af;
  font-size: 0.6875rem;
}
.erp-table__foot strong {
  margin-left: 0.3rem;
  color: #ffffff;
  font-size: 0.8125rem;
}

.erp-salebar {
  position: sticky;
  top: calc(-1 * clamp(0.75rem, 0.5rem + 1.1111111111vw, 1.5rem));
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: calc(-1 * clamp(0.75rem, 0.5rem + 1.1111111111vw, 1.5rem)) calc(-1 * clamp(0.75rem, 0.5rem + 1.1111111111vw, 1.5rem)) 1rem;
  padding: 0.7rem clamp(0.75rem, 0.5rem + 1.1111111111vw, 1.5rem);
  background: #1f2937;
  border-bottom: 1px solid #374151;
}
.erp-salebar__title {
  flex: 1;
  min-width: 0;
}
.erp-salebar h3 {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 700;
}
.erp-salebar p {
  margin: 0.1rem 0 0;
  color: #9ca3af;
  font-size: 0.7rem;
}
@container erp (max-width: 620px) {
  .erp-salebar__new {
    display: none;
  }
}

.erp-card {
  position: relative;
  margin-bottom: 1rem;
  border-radius: 8px;
  background: #1f2937;
  border: 1px solid #374151;
  border-top: 3px solid #0ea5e9;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
}
.erp-card.is-flash {
  animation: cardFlash 1.2s ease-out 2;
}
.erp-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 0.75rem 1rem;
  background: #111827;
  border-bottom: 1px solid #374151;
  border-radius: 5px 5px 0 0;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.8125rem;
}
.erp-card__head > span > i {
  color: #0ea5e9;
  margin-right: 0.35rem;
}
.erp-card__head small {
  display: block;
  margin-top: 0.15rem;
  color: #9ca3af;
  font-weight: 400;
  font-size: 0.6875rem;
}
.erp-card__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

.erp-pad {
  padding: 1rem;
}

.erp-grid2 {
  display: grid;
  gap: 1rem;
  padding: 1rem;
}
@container erp (min-width: 620px) {
  .erp-grid2 {
    grid-template-columns: 1fr 1fr;
  }
}
.erp-grid2--flat {
  padding: 0.9rem 0 0;
}

.erp-field {
  position: relative;
  min-width: 0;
}
.erp-field label {
  display: block;
  margin-bottom: 0.35rem;
  color: #9ca3af;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.erp-input {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  min-height: 40px;
  padding: 0 0.75rem;
  border-radius: 6px;
  border: 1px solid #374151;
  background: #111827;
  color: #ffffff;
  font-size: 0.8125rem;
  text-align: left;
}
.erp-input--barcode {
  width: 11rem;
  min-height: 32px;
  height: 32px;
  font-size: 0.72rem;
  color: #9ca3af;
}
@container erp (max-width: 460px) {
  .erp-input--barcode {
    width: 100%;
  }
}
.erp-input--money {
  width: 100%;
  font-weight: 600;
}
.erp-input.erp-muted, .erp-input .erp-muted {
  color: #9ca3af;
}

.erp-textarea {
  display: block;
  width: 100%;
  padding: 0.6rem 0.75rem;
  border-radius: 6px;
  border: 1px solid #374151;
  background: #111827;
  color: #ffffff;
  font: inherit;
  resize: vertical;
}
.erp-textarea::placeholder {
  color: #9ca3af;
}
.erp-textarea:focus {
  outline: none;
  border-color: #0ea5e9;
  box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.25);
}

.erp-client {
  display: flex;
  gap: 0.5rem;
}
.erp-client__search, .erp-client__add {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 40px;
  border-radius: 6px;
  border: 1px dashed #4b5563;
  background: transparent;
  color: #d1d5db;
  font-size: 0.8rem;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}
.erp-client__search:hover, .erp-client__add:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: #6b7280;
}
.erp-client__search {
  flex: 1;
  min-width: 0;
}
.erp-client__add {
  width: 40px;
  flex-shrink: 0;
  border-color: rgba(16, 185, 129, 0.5);
  color: #34d399;
}
.erp-client__add:hover {
  background: rgba(16, 185, 129, 0.12);
  border-color: #10b981;
}
.erp-client__filled {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-height: 44px;
  padding: 0 0.5rem 0 0.75rem;
  border-radius: 6px;
  border: 1px solid rgba(14, 165, 233, 0.4);
  background: rgba(14, 165, 233, 0.05);
}
.erp-client__filled > i {
  color: #0ea5e9;
  font-size: 1.1rem;
}
.erp-client__filled > span {
  flex: 1;
  min-width: 0;
}
.erp-client__filled b {
  display: block;
  font-size: 0.8125rem;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.erp-client__filled small {
  display: block;
  color: #9ca3af;
  font-size: 0.6875rem;
}
.erp-client__filled button {
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: #9ca3af;
}
.erp-client__filled button:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}
.erp-client__filled button:disabled {
  opacity: 0.4;
}

.erp-dropdown {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 8;
  margin-top: 0.35rem;
  padding: 0.35rem;
  border-radius: 8px;
  background: #111827;
  border: 1px solid #4b5563;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.7);
  animation: simIn 0.25s var(--ease-out);
}
.erp-dropdown[hidden] {
  display: none;
}
.erp-dropdown button {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  width: 100%;
  padding: 0.55rem 0.7rem;
  border: none;
  border-radius: 6px;
  background: transparent;
  text-align: left;
  color: #ffffff;
}
.erp-dropdown button:hover {
  background: rgba(255, 255, 255, 0.07);
}
.erp-dropdown button i {
  color: #0ea5e9;
}
.erp-dropdown button b {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
}
.erp-dropdown button small {
  display: block;
  color: #9ca3af;
  font-size: 0.6875rem;
}

.erp-items__head, .erp-items .erp-item {
  display: grid;
  grid-template-columns: 28px minmax(0, 2.4fr) 112px 70px 100px 100px 64px;
  gap: 0.6rem;
  align-items: center;
  padding: 0 1rem;
}
.erp-items__head {
  min-height: 34px;
  background: #111827;
  border-bottom: 1px solid #374151;
  color: #9ca3af;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.erp-items__head button {
  margin-left: 0.2rem;
  border: none;
  background: none;
  color: #9ca3af;
  padding: 0 0.15rem;
}
.erp-items__head button:hover {
  color: #0ea5e9;
}
.erp-items__head > span:nth-child(n+4):nth-child(-n+6) {
  text-align: right;
}
.erp-items__head > span:nth-child(3) {
  text-align: center;
}
@container erp (max-width: 640px) {
  .erp-items__head {
    display: none;
  }
}

.erp-item {
  min-height: 56px;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #374151;
  font-size: 0.78rem;
}
.erp-item.is-fresh {
  animation: rowFresh 1.2s ease-out;
}
.erp-item__n {
  color: #9ca3af;
  font-size: 0.72rem;
}
.erp-item__name {
  min-width: 0;
}
.erp-item__name b {
  display: block;
  font-weight: 600;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.erp-item__name small {
  display: block;
  color: #9ca3af;
  font-family: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.6875rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.erp-item__cost, .erp-item__unit {
  text-align: right;
  color: #9ca3af;
}
.erp-item__sub {
  text-align: right;
  font-weight: 600;
  color: #ffffff;
}
.erp-item__acts {
  display: flex;
  justify-content: flex-end;
  gap: 0.15rem;
}
.erp-item__acts button {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: #9ca3af;
}
.erp-item__acts button:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.07);
  color: #0ea5e9;
}
.erp-item__acts button[data-del]:hover:not(:disabled), .erp-item__acts button[data-paydel]:hover:not(:disabled) {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
}
.erp-item__acts button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}
@container erp (max-width: 640px) {
  .erp-item {
    grid-template-areas: "name acts" "qty sub";
    row-gap: 0.45rem;
  }
  .erp-item, .erp-items .erp-item {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  .erp-item .erp-item__n, .erp-item .erp-item__cost, .erp-item .erp-item__unit {
    display: none;
  }
  .erp-item .erp-item__name {
    grid-area: name;
  }
  .erp-item .erp-qty {
    grid-area: qty;
    justify-self: start;
  }
  .erp-item .erp-item__sub {
    grid-area: sub;
  }
  .erp-item .erp-item__acts {
    grid-area: acts;
  }
}

.erp-qty {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  justify-self: center;
  padding: 2px;
  border-radius: 6px;
  border: 1px solid #374151;
  background: #111827;
}
.erp-qty button {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border: none;
  border-radius: 4px;
  background: transparent;
}
.erp-qty button:hover:not(:disabled) {
  background: #374151;
}
.erp-qty button:disabled {
  opacity: 0.35;
}
.erp-qty b {
  min-width: 1.2rem;
  text-align: center;
  color: #ffffff;
}
.erp-qty small {
  color: #9ca3af;
  font-size: 0.625rem;
}

.erp-empty {
  margin: 0;
  padding: 1.1rem 1rem;
  text-align: center;
  color: #9ca3af;
  font-size: 0.8rem;
}
.erp-empty--icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  padding: 1.75rem 1rem;
}
.erp-empty--icon > i {
  font-size: 2.2rem;
  color: #6b7280;
  margin-bottom: 0.3rem;
}
.erp-empty--icon > b {
  color: #e5e7eb;
  font-size: 0.8125rem;
}

.erp-totals {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.6rem;
  padding: 0.75rem 1rem;
  background: #111827;
}
@container erp (max-width: 560px) {
  .erp-totals {
    grid-template-columns: 1fr 1fr;
  }
}
.erp-totals > div {
  padding: 0.55rem 0.7rem;
  border-radius: 6px;
  background: #1f2937;
  border: 1px solid #374151;
}
.erp-totals small {
  display: block;
  color: #9ca3af;
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.erp-totals small i {
  font-size: 0.6rem;
  margin-left: 0.2rem;
}
.erp-totals strong {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.9rem;
  color: #ffffff;
}
.erp-totals strong.is-red {
  color: #f87171;
}
.erp-totals .is-final {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.5);
}
.erp-totals .is-final small {
  color: #34d399;
}
.erp-totals .is-final strong {
  color: #10b981;
  font-size: 1.1rem;
}

.erp-hint {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.75rem 1rem;
  padding: 0.5rem 0.8rem;
  border-radius: 12px;
  background: rgba(14, 165, 233, 0.08);
  border: 1px solid rgba(14, 165, 233, 0.25);
  color: #7dd3fc;
  font-size: 0.75rem;
}
.erp-hint[hidden] {
  display: none;
}

.erp-pay {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 1rem;
  border-bottom: 1px solid #374151;
}
.erp-pay__ico {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: var(--c);
  background: color-mix(in srgb, var(--c) 15%, transparent);
}
.erp-pay__name {
  flex: 1;
  min-width: 0;
}
.erp-pay__name b {
  color: #ffffff;
  font-weight: 600;
}
.erp-pay__name small {
  margin-left: 0.3rem;
  color: #9ca3af;
}
.erp-pay__value {
  color: #ffffff;
  font-weight: 600;
}
.erp-pay--modal {
  padding: 0.5rem 0.65rem;
  border: 1px solid #374151;
  border-radius: 8px;
  background: #111827;
  margin-bottom: 0.4rem;
}

.erp-rest {
  padding: 0.7rem 1rem;
  text-align: right;
  color: #9ca3af;
  font-size: 0.78rem;
}
.erp-rest strong {
  margin-left: 0.3rem;
  font-size: 0.9rem;
  color: #f87171;
}
.erp-rest strong.is-zero {
  color: #10b981;
}

.erp-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.9rem 1rem;
}
@container erp (min-width: 720px) {
  .erp-actions__end {
    margin-left: auto;
  }
}

.erp-note {
  padding: 0.9rem 1rem;
}
.erp-note__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}
.erp-note__top b {
  color: #ffffff;
  font-weight: 600;
}
.erp-note__btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-left: auto;
}
.erp-note__key {
  margin-top: 0.5rem;
  font-size: 0.6875rem;
  color: #9ca3af;
  word-break: break-all;
}
.erp-note__key .erp-mono {
  font-size: 1em;
}

.erp-modal {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(0, 0, 0, 0);
  transition: background-color 0.3s ease;
}
@media (max-width: 575.98px) {
  .erp-modal {
    padding: 0.35rem;
  }
}
.erp-modal[hidden] {
  display: none;
}
.erp-modal.is-open {
  background: rgba(0, 0, 0, 0.6);
}
.erp-modal.is-open .erp-modal__box {
  opacity: 1;
  translate: 0 0;
  scale: 1;
}
.erp-modal__box {
  width: min(520px, 100%);
  max-height: 100%;
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  background: #1f2937;
  border: 1px solid #374151;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.75);
  opacity: 0;
  translate: 0 18px;
  scale: 0.97;
  transition: opacity 0.3s ease, translate 0.4s var(--ease-out), scale 0.4s var(--ease-out);
  overflow: hidden;
}
.erp-modal__box--products {
  width: min(1000px, 100%);
  height: 88%;
}
.erp-modal__box--pay {
  width: min(860px, 100%);
}
.erp-modal__box--emit {
  width: min(640px, 100%);
}
.erp-modal__box--doc {
  width: min(460px, 100%);
}
.erp-modal__head {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 1rem;
  background: #111827;
  border-bottom: 1px solid #374151;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.8125rem;
}
.erp-modal__head button {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border: none;
  border-radius: 6px;
  background: none;
  color: #9ca3af;
  font-size: 0.95rem;
}
.erp-modal__head button:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}
.erp-modal__body {
  padding: 1rem;
  overflow-y: auto;
  min-height: 0;
  flex: 1;
  scrollbar-width: thin;
}
.erp-modal__foot {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  padding: 0.65rem 1rem;
  background: #111827;
  border-top: 1px solid #374151;
  font-size: 0.75rem;
  color: #d1d5db;
}
.erp-modal__foot b.is-red {
  color: #f87171;
}
.erp-modal__foot b.is-green {
  color: #34d399;
}
.erp-modal__btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.erp-modal__body.erp-pq {
  display: flex;
  flex-direction: column;
  padding: 0.9rem 1rem 0;
  overflow: hidden;
}

.erp-pq__tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  margin-bottom: 0.75rem;
  font-size: 0.75rem;
  color: #d1d5db;
}
.erp-pq__table {
  flex: 1;
  min-height: 0;
  overflow: auto;
  border: 1px solid #374151;
  border-radius: 8px 8px 0 0;
  scrollbar-width: thin;
}
.erp-pq__head, .erp-pq .erp-prow {
  display: grid;
  align-items: center;
  gap: 0.6rem;
  padding: 0 0.75rem;
  grid-template-columns: 28px minmax(260px, 2.4fr) 70px 100px 100px 100px 70px 90px 80px 100px;
  min-width: 1000px;
}
.erp-pq__head .c, .erp-pq .erp-prow .c {
  text-align: center;
}
.erp-pq__head .r, .erp-pq .erp-prow .r {
  text-align: right;
}
@container erpf (max-width: 640px) {
  .erp-pq__head, .erp-pq .erp-prow {
    grid-template-columns: 24px minmax(0, 1fr) 54px 84px;
    min-width: 0;
  }
  .erp-pq__head .x, .erp-pq .erp-prow .x {
    display: none;
  }
}
.erp-pq__head {
  position: sticky;
  top: 0;
  z-index: 2;
  min-height: 34px;
  background: #374151;
  border-bottom: 2px solid #4b5563;
  color: #e5e7eb;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.erp-pq__mode {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  color: #9ca3af;
}
.erp-pq__total b {
  color: #ffffff;
}

.erp-chipbtn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  height: 28px;
  padding: 0 0.65rem;
  border-radius: 6px;
  border: 1px solid #4b5563;
  background: #374151;
  color: #e5e7eb;
  font-size: 0.6875rem;
  font-weight: 500;
  white-space: nowrap;
}
.erp-chipbtn small {
  color: #b6bcc7;
}
.erp-chipbtn:hover {
  background: #4b5563;
}
.erp-chipbtn--sky {
  margin-left: auto;
  color: #7dd3fc;
  background: rgba(14, 165, 233, 0.12);
  border-color: rgba(14, 165, 233, 0.35);
}
.erp-chipbtn--sky:hover {
  background: rgba(14, 165, 233, 0.22);
}
@container erpf (max-width: 640px) {
  .erp-chipbtn--sky {
    margin-left: 0;
  }
}

.erp-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  cursor: pointer;
  white-space: nowrap;
}
.erp-switch input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.erp-switch > span {
  position: relative;
  width: 36px;
  height: 20px;
  flex-shrink: 0;
  border-radius: 20px;
  background: #4b5563;
  transition: background-color 0.2s ease;
}
.erp-switch > span::after {
  content: "";
  position: absolute;
  left: 2px;
  top: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #ffffff;
  transition: translate 0.2s ease;
}
.erp-switch input:checked + span {
  background: #0369a1;
}
.erp-switch input:checked + span::after {
  translate: 16px 0;
}
.erp-switch input:focus-visible + span {
  outline: 2px solid #0ea5e9;
  outline-offset: 2px;
}

.erp-prow {
  min-height: 54px;
  padding-top: 0.4rem;
  padding-bottom: 0.4rem;
  background: #1f2937;
  border-top: 1px solid #374151;
  border-left: 3px solid transparent;
  font-size: 0.75rem;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}
.erp-prow:hover {
  background: rgba(55, 65, 81, 0.7);
  border-left-color: #0ea5e9;
}
.erp-prow:hover .erp-prow__name b {
  color: #7dd3fc;
}
.erp-prow.is-added {
  background: rgba(16, 185, 129, 0.07);
}
.erp-prow.is-zero {
  opacity: 0.6;
}
.erp-prow.is-flash {
  animation: rowFresh 1.2s ease-out;
}
.erp-prow__chev {
  color: #9ca3af;
  font-size: 0.7rem;
}
.erp-prow__name {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}
.erp-prow__name > span:last-child {
  min-width: 0;
}
.erp-prow__name b {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color 0.15s ease;
}
.erp-prow__name small {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.2rem 0.4rem;
  margin-top: 0.15rem;
  color: #9ca3af;
  font-size: 0.625rem;
}
.erp-prow__thumb {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: #111827;
  border: 1px solid #374151;
  color: #6b7280;
}
.erp-prow__price {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #34d399;
}
.erp-prow .is-red {
  color: #f87171;
  font-weight: 600;
}

.erp-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0 0.35rem;
  border-radius: 4px;
  font-style: normal;
  font-family: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.5625rem;
  line-height: 1.6;
  background: #111827;
  border: 1px solid #4b5563;
  color: #d1d5db;
}
.erp-chip--amber {
  font-family: inherit;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.3);
}
.erp-chip--green {
  font-family: inherit;
  color: #34d399;
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.3);
}

.erp-dots {
  letter-spacing: 0.15em;
  color: #9ca3af;
}

.erp-pm {
  display: grid;
  gap: 1.25rem;
}
@container erpf (min-width: 700px) {
  .erp-pm {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  }
}
.erp-pm__tiles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.erp-pm__tiles > div {
  position: relative;
  padding: 0.6rem 0.7rem;
  border-radius: 8px;
  background: #111827;
  border: 1px solid #374151;
  border-left: 3px solid var(--c);
}
.erp-pm__tiles > div.is-sky {
  --c: #0ea5e9;
}
.erp-pm__tiles > div.is-green {
  --c: #10b981;
}
.erp-pm__tiles > div.is-amber {
  --c: #f59e0b;
}
.erp-pm__tiles > div > i {
  position: absolute;
  right: 0.6rem;
  top: 0.55rem;
  color: var(--c);
}
.erp-pm__tiles > div small {
  display: block;
  color: #9ca3af;
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.erp-pm__tiles > div b {
  display: block;
  margin-top: 0.1rem;
  font-size: 0.95rem;
  color: #ffffff;
}
.erp-pm__tiles > div b.is-red {
  color: #f87171;
}
.erp-pm__methods {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
}
@container erpf (max-width: 560px) {
  .erp-pm__methods {
    grid-template-columns: repeat(3, 1fr);
  }
}
.erp-pm__methods button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  min-height: 58px;
  padding: 0.3rem;
  border-radius: 8px;
  border: 1px solid #374151;
  background: #111827;
  font-size: 0.625rem;
  font-weight: 700;
  color: #e5e7eb;
  transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}
.erp-pm__methods button i {
  color: color-mix(in srgb, var(--c) 65%, #fff);
  font-size: 1.1rem;
}
.erp-pm__methods button:hover:not(:disabled) {
  border-color: var(--c);
}
.erp-pm__methods button.is-selected {
  border-color: var(--c);
  background: color-mix(in srgb, var(--c) 10%, transparent);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--c) 30%, transparent);
}
.erp-pm__methods button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.erp-pm__empty {
  margin: 0 0 0.75rem;
  padding: 1.1rem 0.9rem;
  text-align: center;
  border-radius: 8px;
  border: 1px dashed #4b5563;
  color: #9ca3af;
  font-size: 0.75rem;
}
.erp-pm__list {
  margin-bottom: 0.75rem;
}
.erp-pm__add {
  display: flex;
  align-items: flex-end;
  gap: 0.6rem;
}
.erp-pm__add label {
  flex: 1;
  min-width: 0;
}
.erp-pm__add .erp-btn {
  flex-shrink: 0;
  height: 40px;
}

.erp-label {
  display: block;
  margin: 0 0 0.45rem;
  color: #9ca3af;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.erp-tabs {
  flex-shrink: 0;
  display: flex;
  gap: 0.25rem;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  padding: 0 0.75rem;
  background: #111827;
  border-bottom: 1px solid #374151;
}
.erp-tabs > span, .erp-tabs > button {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.6rem 0.75rem;
  border: none;
  border-bottom: 2px solid transparent;
  background: none;
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
  color: #9ca3af;
  margin-bottom: -1px;
}
.erp-tabs > button:hover {
  color: #e5e7eb;
}
.erp-tabs > .is-active {
  color: #7dd3fc;
  border-bottom-color: #0ea5e9;
}

.erp-seg {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  margin-bottom: 0.5rem;
  border-radius: 8px;
  background: #111827;
  border: 1px solid #374151;
}
.erp-seg button {
  padding: 0.4rem 0.9rem;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: #9ca3af;
  font-size: 0.75rem;
  font-weight: 500;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.erp-seg button:hover {
  color: #e5e7eb;
}
.erp-seg button.is-selected {
  background: #374151;
  color: #7dd3fc;
  font-weight: 700;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

.erp-result {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  margin-top: 0.9rem;
  padding: 0.8rem 0.9rem;
  border-radius: 8px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.4);
}
.erp-result > i {
  color: #10b981;
  font-size: 1.2rem;
}
.erp-result > div {
  min-width: 0;
}
.erp-result b {
  display: block;
  color: #34d399;
}
.erp-result span {
  display: block;
  margin-top: 0.15rem;
  color: #d1d5db;
  font-size: 0.6875rem;
  word-break: break-all;
}
.erp-result[hidden] {
  display: none;
}

.sim-progress {
  list-style: none;
  margin: 0.9rem 0 0;
  padding: 0;
}
.sim-progress li {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.35rem 0;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.86rem;
  animation: simIn 0.3s var(--ease-out);
}
.sim-progress li.is-done {
  color: #ffffff;
}
.sim-progress li.is-done:last-child {
  color: #4ade80;
  font-weight: 700;
}
.sim-progress__dot {
  position: relative;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.2);
}
.is-running .sim-progress__dot {
  border-top-color: #3b82f6;
  animation: simSpin 0.7s linear infinite;
}
.is-done .sim-progress__dot {
  background: #16a34a;
  border-color: #16a34a;
}
.is-done .sim-progress__dot::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 2px;
  width: 5px;
  height: 9px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  rotate: 45deg;
}

.is-guided {
  position: relative;
  z-index: 2;
  animation: guidePulse 1.6s infinite;
  outline: 2px solid rgba(255, 75, 66, 0.9);
  outline-offset: 2px;
}

.sim-coach {
  position: absolute;
  z-index: 30;
  translate: -50% 0;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.85rem;
  border-radius: 10px;
  background: var(--brand-grad);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 14px 30px -8px rgba(255, 75, 66, 0.7);
  pointer-events: none;
  animation: coachBob 1.6s ease-in-out infinite;
}
.sim-coach::before {
  content: "";
  position: absolute;
  left: calc(50% + var(--arrow-x, 0px));
  top: -6px;
  width: 12px;
  height: 12px;
  translate: -50% 0;
  rotate: 45deg;
  background: #ff6b5e;
}
.sim-coach.is-above::before {
  top: auto;
  bottom: -6px;
}

.erp-toast {
  position: absolute;
  left: 50%;
  bottom: 1rem;
  z-index: 40;
  translate: -50% 0;
  padding: 0.6rem 1rem;
  border-radius: 10px;
  background: #0b1016;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #ffffff;
  font-size: 0.8rem;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.7);
  white-space: nowrap;
}
.erp-toast.is-in {
  animation: simIn 0.3s var(--ease-out);
}

.sim-qr {
  display: grid;
  grid-template-columns: repeat(21, 1fr);
  flex-shrink: 0;
  width: 72px;
  aspect-ratio: 1;
  background: #ffffff;
}
.sim-qr i.on {
  background: #0b1016;
}

.sim-doc {
  position: relative;
  overflow: hidden;
  padding: 1.1rem 1.2rem;
  border-radius: 10px;
  background: #fbfaf7;
  color: #1d1d1f;
  font-size: 0.78rem;
}
.sim-doc__stamp {
  display: inline-block;
  margin-top: 0.4rem;
  padding: 0.25rem 0.6rem;
  border: 2px solid #16a34a;
  border-radius: 6px;
  color: #16a34a;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  rotate: -8deg;
  animation: stampIn 0.45s cubic-bezier(0.34, 1.6, 0.64, 1) 0.3s both;
}
.sim-doc__watermark {
  position: absolute;
  left: 50%;
  top: 52%;
  translate: -50% -50%;
  rotate: -22deg;
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  color: rgba(255, 75, 66, 0.13);
  pointer-events: none;
}
.sim-doc__head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.6rem;
  margin-bottom: 0.6rem;
  border-bottom: 1px dashed #c8c8c8;
}
.sim-doc__head strong {
  display: block;
  font-size: 1.05rem;
}
.sim-doc__head small {
  display: block;
  color: #666;
  font-size: 0.66rem;
}
.sim-doc__num {
  text-align: right;
  font-family: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
}
.sim-doc__row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.15rem 0;
}
.sim-doc__row small {
  color: #777;
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.sim-doc__row span {
  font-weight: 600;
  text-align: right;
}
.sim-doc__row em {
  color: #999;
  font-style: normal;
  font-weight: 400;
}
.sim-doc__items {
  list-style: none;
  margin: 0.6rem 0;
  padding: 0.5rem 0;
  border-top: 1px dashed #c8c8c8;
  border-bottom: 1px dashed #c8c8c8;
}
.sim-doc__items li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.15rem 0;
}
.sim-doc__total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 0.75rem;
}
.sim-doc__total strong {
  font-size: 1.05rem;
}
.sim-doc__foot {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 0.75rem;
  align-items: center;
}
.sim-doc__foot small {
  display: block;
  color: #777;
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.sim-doc__foot code {
  display: block;
  margin-bottom: 0.35rem;
  font-family: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.64rem;
  color: #333;
  word-break: break-all;
}

.sim-backstage {
  display: grid;
  gap: 0.7rem;
}
@media (min-width: 992px) {
  .sim-backstage {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1200px) {
  .sim-backstage {
    grid-template-columns: 1fr;
    position: sticky;
    top: 100px;
  }
}
@media (min-width: 992px) {
  .sim-backstage__head {
    grid-column: 1/-1;
  }
}
@media (min-width: 1200px) {
  .sim-backstage__head {
    grid-column: auto;
  }
}
.sim-backstage__head p {
  margin: 0.3rem 0 0.25rem;
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.86rem;
}
.sim-backstage__kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #ff6b5e;
}

.sim-bk {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 0.85rem;
  align-items: center;
  padding: 0.9rem 1rem;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  opacity: 0.55;
  transition: opacity 0.5s ease, border-color 0.5s ease, background-color 0.5s ease;
}
.sim-bk__icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff;
  font-size: 1.15rem;
  transition: background-color 0.5s ease, color 0.5s ease;
}
.sim-bk strong {
  display: block;
  color: #ffffff;
  font-size: 0.9rem;
}
.sim-bk small {
  display: block;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.78rem;
  line-height: 1.4;
}
.sim-bk__check {
  color: #4ade80;
  font-size: 1.15rem;
  opacity: 0;
  scale: 0.4;
  transition: opacity 0.4s ease, scale 0.45s cubic-bezier(0.34, 1.6, 0.64, 1);
}
.sim-bk.is-live {
  opacity: 1;
  border-color: rgba(74, 222, 128, 0.35);
  background: rgba(74, 222, 128, 0.05);
}
.sim-bk.is-live .sim-bk__icon {
  background: rgba(74, 222, 128, 0.15);
  color: #4ade80;
}
.sim-bk.is-live .sim-bk__check {
  opacity: 1;
  scale: 1;
}
.sim-bk.is-live small {
  color: rgba(255, 255, 255, 0.85);
}

.sim-bars {
  grid-column: 1/-1;
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 50px;
  margin-top: 0.25rem;
}
.sim-bars span {
  flex: 1;
  height: var(--h);
  border-radius: 5px 5px 0 0;
  background: rgba(255, 255, 255, 0.12);
  transition: height 0.9s var(--ease-out);
}
.sim-bars span:last-child {
  background: var(--brand-grad);
}

.sim-disclaimer {
  display: flex;
  gap: 0.45rem;
  margin: 0.25rem 0 0;
  font-size: 0.74rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.45);
}
@media (min-width: 992px) {
  .sim-disclaimer {
    grid-column: 1/-1;
  }
}
@media (min-width: 1200px) {
  .sim-disclaimer {
    grid-column: auto;
  }
}

.sim-finish {
  margin-top: 1.5rem;
  padding: clamp(1.25rem, 1.0833333333rem + 0.7407407407vw, 1.75rem);
  border-radius: 20px;
  border: 1px solid rgba(74, 222, 128, 0.3);
  background: radial-gradient(60% 120% at 0% 0%, rgba(74, 222, 128, 0.1), transparent 70%), rgba(255, 255, 255, 0.03);
  text-align: center;
  opacity: 0;
  translate: 0 16px;
  transition: opacity 0.5s ease, translate 0.6s var(--ease-out);
}
.sim-finish.is-in {
  opacity: 1;
  translate: 0 0;
}
.sim-finish__time {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  color: #ffffff;
}
.sim-finish__time i {
  color: #ffb347;
}
.sim-finish__time strong {
  font-family: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  background: var(--brand-grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.sim-finish__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
}
@media (max-width: 575.98px) {
  .sim-finish__actions .btn-hero {
    width: 100%;
    justify-content: center;
  }
}
.sim-finish__more {
  margin: 1rem 0 0;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.55);
}
.sim-finish__more strong {
  color: #ffffff;
}

.sim-back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: none;
  background: none;
  padding: 0.5rem 0.25rem;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.88rem;
  font-weight: 600;
}
.sim-back:hover {
  color: #ffffff;
}

html[data-motion=reduced] .is-guided, html[data-motion=reduced] .sim-coach {
  animation: none;
}

.erp {
  scrollbar-width: thin;
  scrollbar-color: #4b5563 transparent;
}
.erp *::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
.erp *::-webkit-scrollbar-track {
  background: transparent;
}
.erp *::-webkit-scrollbar-thumb {
  background: #4b5563;
  border-radius: 6px;
}
.erp * {
  scrollbar-width: thin;
  scrollbar-color: #4b5563 transparent;
}
