:root {
  font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  color: #212a3b;
  background: #f5f7fa;
  --blue: #0864d8;
  --yellow: #ffdc35;
  --line: #e7ebf1;
  --muted: #8a94a5;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
button:focus-visible,
a:focus-visible {
  outline: 3px solid #4e97f5;
  outline-offset: 3px;
}
input,
select,
textarea {
  border: 1px solid #dce2eb;
  border-radius: 9px;
  padding: 11px 12px;
  min-height: 42px;
  background: #fff;
  color: #212a3b;
  width: 100%;
  font-size: 13px;
}
input:focus,
select:focus,
textarea:focus {
  outline: 2px solid #0864d833;
  border-color: #0864d8;
}
textarea {
  resize: vertical;
  min-height: 105px;
  line-height: 1.8;
}
input[type='checkbox'] {
  width: 16px;
  min-height: 16px;
  accent-color: var(--blue);
}
button {
  border: 0;
  background: none;
  color: inherit;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
.loading {
  padding: 70px;
  text-align: center;
  color: var(--muted);
}
.login {
  min-height: 100dvh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.login-art {
  background: #0864d8;
  color: #fff;
  position: relative;
  overflow: hidden;
  padding: 60px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.login-art:after {
  content: '↗';
  font-size: 570px;
  line-height: 1;
  position: absolute;
  right: -60px;
  bottom: -70px;
  color: #ffffff0b;
  pointer-events: none;
}
.login-art .logo {
  width: 60px;
  height: 76px;
  border-radius: 8px;
}
.login-art h1 {
  font-size: 52px;
  letter-spacing: -2px;
  line-height: 1.3;
  margin-bottom: 25px;
}
.login-art p {
  font-size: 14px;
  color: #d4e6ff;
  line-height: 1.8;
}
.login-art small {
  font-size: 11px;
  letter-spacing: 2px;
  color: #adcff9;
}
.login-form-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 35px;
  background: #fff;
}
.login-form {
  max-width: 350px;
  width: 100%;
}
.eyebrow {
  font-size: 10px;
  letter-spacing: 2px;
  font-weight: 700;
  color: #8493a9;
  margin-bottom: 15px;
}
.login-form h2 {
  font-size: 28px;
  margin-bottom: 12px;
}
.login-form > p {
  font-size: 13px;
  color: #8a94a5;
  line-height: 1.8;
  margin-bottom: 35px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin: 0 0 19px;
}
.field > span,
.field > label {
  font-size: 12px;
  font-weight: 600;
}
.field small {
  font-size: 11px;
  line-height: 1.6;
  color: #8a94a5;
}
.primary {
  background: var(--blue);
  color: #fff;
  border-radius: 9px;
  padding: 11px 18px;
  font-size: 12px;
  font-weight: 600;
  min-height: 40px;
}
.primary.yellow {
  background: var(--yellow);
  color: #322e17;
}
.secondary {
  background: #f0f4fa;
  border: 1px solid #e1e7f0;
  border-radius: 9px;
  padding: 10px 17px;
  font-size: 12px;
  min-height: 40px;
}
.danger {
  color: #d94c46;
  background: #fff1f0;
  border-radius: 7px;
  font-size: 11px;
  padding: 8px 11px;
}
.wide {
  width: 100%;
}
.form-error {
  min-height: 20px;
  color: #d94c46;
  font-size: 12px;
  line-height: 1.7;
  margin: 15px 0;
}
.layout {
  display: grid;
  grid-template-columns: 218px minmax(0, 1fr);
  min-height: 100dvh;
}
.sidebar {
  width: 218px;
  position: fixed;
  inset: 0 auto 0 0;
  background: white;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: 25px 15px;
  z-index: 15;
}
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 0 10px 25px;
  margin-bottom: 6px;
}
.sidebar-brand img {
  width: 36px;
  height: 46px;
  border-radius: 5px;
}
.sidebar-brand strong {
  font-size: 15px;
  letter-spacing: 1px;
  display: block;
}
.sidebar-brand small {
  font-size: 8px;
  letter-spacing: 1.5px;
  color: #9ca6b4;
  display: block;
  margin-top: 6px;
}
.nav-group {
  font-size: 9px;
  letter-spacing: 1px;
  color: #a7afbb;
  padding: 20px 15px 10px;
}
.nav-item {
  display: flex;
  width: 100%;
  gap: 11px;
  align-items: center;
  text-align: left;
  font-size: 12px;
  padding: 12px 15px;
  margin: 2px 0;
  border-radius: 8px;
  color: #707e93;
}
.nav-item svg {
  width: 17px;
  height: 17px;
}
.nav-item:hover {
  background: #f5f8fc;
}
.nav-item.active {
  background: #eaf2ff;
  color: #0864d8;
  font-weight: 600;
}
.sidebar-bottom {
  margin-top: auto;
  padding: 22px 10px 0;
}
.store-indicator {
  font-size: 10px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: #799089;
}
.store-indicator:before {
  content: '';
  width: 6px;
  height: 6px;
  background: #43a678;
  border-radius: 50%;
}
.main {
  grid-column: 2;
  min-width: 0;
}
.topbar {
  height: 76px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 35px;
  gap: 20px;
}
.breadcrumbs {
  font-size: 11px;
  color: #9ca5b3;
}
.breadcrumbs span {
  color: #3d495d;
  margin-left: 12px;
}
.top-right {
  display: flex;
  align-items: center;
  gap: 15px;
  font-size: 11px;
  color: #7a879b;
}
.mode {
  font-size: 10px;
  background: #fff6ce;
  color: #a27d17;
  padding: 6px 10px;
  border-radius: 5px;
}
.mode-production {
  background: #e9f6ee;
  color: #216044;
}
.coach-thumb {
  display: block;
  width: 56px;
  height: 56px;
  margin-top: 8px;
  border-radius: 16px;
  object-fit: cover;
}
.avatar {
  height: 29px;
  width: 29px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #eaf2ff;
  color: #0864d8;
  font-weight: 700;
  font-size: 12px;
}
.logout {
  font-size: 11px;
  color: #98a2b1;
}
.content {
  padding: 32px 35px 60px;
  max-width: 1600px;
  margin: 0 auto;
}
.page-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 25px;
}
.page-title-row h1 {
  font-size: 24px;
  letter-spacing: -0.5px;
  margin-bottom: 8px;
}
.page-title-row p {
  font-size: 12px;
  color: #95a0b1;
  margin-bottom: 0;
}
.date-label {
  font-size: 11px;
  color: #95a0b1;
}
.kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.kpi {
  background: white;
  padding: 23px;
  border: 1px solid var(--line);
  border-radius: 13px;
}
.kpi-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: #8a94a5;
}
.kpi-head svg {
  width: 17px;
  height: 17px;
  color: #0864d8;
}
.kpi strong {
  display: block;
  font-size: 30px;
  font-weight: 650;
  letter-spacing: -1px;
  margin: 22px 0 10px;
}
.kpi p {
  font-size: 10px;
  color: #a4adba;
  margin-bottom: 0;
}
.welcome-card {
  background: #0864d8;
  color: white;
  border-radius: 14px;
  padding: 28px 32px;
  margin-bottom: 25px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.welcome-card:after {
  content: '↗';
  position: absolute;
  right: 24px;
  bottom: -52px;
  font-size: 210px;
  color: #ffffff0d;
}
.welcome-card h2 {
  font-size: 23px;
  margin: 0 0 12px;
}
.welcome-card p {
  font-size: 12px;
  line-height: 1.8;
  color: #d1e5ff;
  margin: 0;
  max-width: 75%;
}
.welcome-card .primary {
  position: relative;
  z-index: 1;
}
.panels {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 20px;
  margin-top: 24px;
}
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: 13px;
  overflow: hidden;
}
.panel-title {
  font-size: 13px;
  font-weight: 650;
  padding: 22px 24px;
  border-bottom: 1px solid #f0f2f5;
  display: flex;
  justify-content: space-between;
}
.panel-title button {
  font-size: 10px;
  color: #8d99a9;
  font-weight: 400;
}
.panel-body {
  padding: 24px;
}
.quick-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 13px;
}
.quick-action {
  background: #f5f8fd;
  border: 1px solid #edf1f6;
  border-radius: 10px;
  text-align: left;
  padding: 21px 15px;
  font-size: 11px;
}
.quick-action svg {
  display: block;
  width: 24px;
  height: 24px;
  color: #0864d8;
  margin-bottom: 14px;
}
.checklist {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.checklist > div {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  color: #8390a3;
}
.check-bullet {
  background: #f0f6ff;
  border-radius: 50%;
  color: #0864d8;
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  font-size: 11px;
}
.checklist b {
  font-weight: 500;
  color: #41516a;
}
.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin: 0 0 20px;
}
.toolbar select {
  width: auto;
  max-width: 260px;
  font-size: 11px;
}
.toolbar input {
  max-width: 240px;
  font-size: 11px;
}
.toolbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
}
.table-wrap {
  overflow: auto;
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
}
table {
  border-collapse: collapse;
  width: 100%;
  text-align: left;
  font-size: 11px;
  white-space: nowrap;
}
th {
  background: #fafbfd;
  color: #96a0af;
  font-weight: 500;
  font-size: 10px;
  padding: 16px 19px;
  border-bottom: 1px solid var(--line);
}
td {
  padding: 18px 19px;
  border-bottom: 1px solid #eef1f5;
  max-width: 320px;
  overflow: hidden;
  text-overflow: ellipsis;
}
tr:last-child td {
  border: 0;
}
td strong {
  font-weight: 600;
  color: #3a495f;
}
td small {
  display: block;
  color: #9aa5b5;
  font-size: 10px;
  margin-top: 7px;
}
td .row-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}
.text-button {
  font-size: 11px;
  color: #0864d8;
  padding: 5px;
}
.badge {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 5px;
  font-size: 9px;
  font-weight: 500;
  color: #75849a;
  background: #f0f3f7;
}
.badge.success {
  background: #eaf8ef;
  color: #4b9c6b;
}
.badge.warn {
  background: #fff7dc;
  color: #a38830;
}
.badge.danger {
  background: #fff0ef;
  color: #ca6f69;
}
.badge.blue {
  background: #edf4ff;
  color: #5587ca;
}
.empty {
  padding: 65px 25px;
  text-align: center;
  font-size: 12px;
  color: #a2abba;
}
.table-note {
  font-size: 10px;
  color: #a6afbd;
  margin-top: 15px;
}
.store-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}
.store-panel {
  padding: 25px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.store-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 19px;
}
.store-panel-head h2 {
  font-size: 17px;
  margin: 0;
}
.store-panel p {
  font-size: 11px;
  line-height: 1.9;
  color: #8997aa;
  margin-bottom: 8px;
}
.store-panel .tags {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin: 16px 0 20px;
}
.store-panel .tags span {
  font-size: 9px;
  background: #f3f6fc;
  color: #7e8da2;
  border-radius: 4px;
  padding: 5px 7px;
}
.store-panel > button {
  margin-top: 8px;
}
.settings-tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 25px;
}
.settings-tabs button {
  font-size: 11px;
  padding: 10px 16px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #8090a6;
}
.settings-tabs .active {
  border-color: #0864d8;
  background: #edf4ff;
  color: #0864d8;
}
.settings-panel {
  max-width: 800px;
  background: white;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.settings-panel .field {
  margin-bottom: 23px;
}
.settings-panel .legal-text {
  height: 360px;
  line-height: 2;
}
.inline-notice {
  padding: 14px 17px;
  background: #fff9e4;
  border: 1px solid #f5eac4;
  color: #a38943;
  font-size: 11px;
  line-height: 1.8;
  border-radius: 9px;
  margin-bottom: 23px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 20px;
}
.span-2 {
  grid-column: 1/-1;
}
.check-field {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12px;
  margin: 15px 0 23px;
}
.checkbox-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 13px;
}
.checkbox-grid label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
}
.overlay {
  position: fixed;
  inset: 0;
  background: #17294466;
  backdrop-filter: blur(4px);
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.dialog {
  position: relative;
  background: white;
  width: 100%;
  max-width: 650px;
  max-height: 90dvh;
  overflow: auto;
  border-radius: 16px;
  padding: 30px;
}
.dialog h2 {
  font-size: 21px;
  margin-bottom: 25px;
}
.close {
  position: absolute;
  right: 20px;
  top: 18px;
  border-radius: 50%;
  background: #f1f4f8;
  width: 28px;
  height: 28px;
  font-size: 20px;
  color: #8c99ad;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 20px;
  padding-top: 22px;
  border-top: 1px solid #eef1f5;
}
.checkin-box {
  max-width: 650px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 30px;
}
.checkin-box textarea {
  height: 140px;
}
.checkin-result {
  margin-top: 25px;
  border-top: 1px solid var(--line);
  padding-top: 25px;
}
.checkin-result h2 {
  font-size: 20px;
}
.checkin-result p {
  font-size: 12px;
  color: #8a94a5;
}
.actions {
  display: flex;
  gap: 10px;
}
.error-state {
  background: #fff1ef;
  border-radius: 10px;
  color: #b65f54;
  padding: 20px;
  font-size: 12px;
}
.upload {
  font-size: 11px;
}
.upload input {
  font-size: 11px;
}
.store-thumb {
  height: 130px;
  width: 100%;
  object-fit: cover;
  border-radius: 9px;
  margin-bottom: 20px;
}
#toast {
  position: fixed;
  left: 50%;
  bottom: 35px;
  transform: translate(-50%, 15px);
  background: #20314ded;
  color: white;
  padding: 13px 22px;
  border-radius: 9px;
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transition: 0.2s;
  z-index: 80;
  max-width: 90vw;
}
#toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}
@media (max-width: 1100px) {
  .kpis {
    grid-template-columns: repeat(2, 1fr);
  }
  .panels {
    grid-template-columns: 1fr;
  }
  .content {
    padding: 25px;
  }
  .topbar {
    padding: 0 25px;
  }
  .welcome-card p {
    max-width: 90%;
  }
}
@media (max-width: 760px) {
  .layout {
    grid-template-columns: 68px minmax(0, 1fr);
  }
  .sidebar {
    width: 68px;
    padding: 18px 7px;
  }
  .sidebar-brand {
    padding: 0 7px 15px;
  }
  .sidebar-brand img {
    width: 35px;
    height: 44px;
  }
  .sidebar-brand > div,
  .nav-item span,
  .nav-group,
  .sidebar-bottom {
    display: none;
  }
  .nav-item {
    justify-content: center;
    padding: 14px 10px;
  }
  .nav-item svg {
    width: 21px;
    height: 21px;
  }
  .topbar {
    height: 65px;
    padding: 0 18px;
  }
  .breadcrumbs {
    font-size: 9px;
  }
  .top-right {
    gap: 8px;
  }
  .top-right > .account-email {
    display: none;
  }
  .content {
    padding: 23px 17px;
  }
  .page-title-row h1 {
    font-size: 20px;
  }
  .page-title-row p {
    font-size: 10px;
    line-height: 1.7;
  }
  .date-label {
    display: none;
  }
  .welcome-card {
    padding: 24px;
    display: block;
  }
  .welcome-card h2 {
    font-size: 21px;
  }
  .welcome-card p {
    font-size: 11px;
    max-width: 100%;
    margin-bottom: 20px;
  }
  .kpis {
    gap: 10px;
  }
  .kpi {
    padding: 18px;
  }
  .kpi strong {
    font-size: 25px;
  }
  .kpi-head {
    font-size: 10px;
  }
  .kpi p {
    font-size: 9px;
  }
  .quick-actions {
    grid-template-columns: 1fr;
  }
  .quick-action {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 17px;
  }
  .quick-action svg {
    margin: 0;
  }
  .login {
    grid-template-columns: 1fr;
  }
  .login-art {
    display: none;
  }
  .login-form-wrap {
    padding: 35px;
  }
  .toolbar {
    flex-wrap: wrap;
  }
  .toolbar-left {
    width: 100%;
  }
  .toolbar input {
    max-width: none;
  }
  .toolbar select {
    max-width: 100%;
  }
  .page-title-row .primary {
    white-space: nowrap;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .span-2 {
    grid-column: 1;
  }
  .dialog {
    padding: 25px;
  }
  .overlay {
    padding: 15px;
  }
  .settings-panel {
    padding: 23px;
  }
  .store-grid {
    grid-template-columns: 1fr;
  }
  .mode {
    font-size: 9px;
    padding: 5px 7px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}

.recent-panel {
  margin-top: 24px;
}

.sidebar {
  overflow-y: auto;
}
.sidebar > * {
  flex-shrink: 0;
}

.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}
.sidebar-nav .nav-group {
  padding: 16px 12px 6px;
  font-size: 11px;
  color: #576a80;
}
.sidebar-nav .nav-item {
  padding: 9px 12px;
}
.sidebar-nav .nav-item:focus-visible {
  outline: 2px solid #174ed0;
  outline-offset: -2px;
}
.sidebar-bottom {
  padding-top: 12px;
}
.welcome-card:after {
  content: none;
}
@media (max-width: 760px) {
  .sidebar-nav .nav-item {
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    padding: 7px 3px;
  }
  .sidebar-nav .nav-item span {
    display: block;
    font-size: 9px;
    white-space: nowrap;
  }
}

.pagination {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 9px;
  margin-top: 12px;
  font-size: 12px;
}
.pagination span {
  margin-right: 6px;
  color: #576a80;
}
#order-filter input {
  width: min(300px, 100%);
}
#order-filter .toolbar-left {
  flex-wrap: wrap;
}
