/* ============================================================
   page-vendor-index.css — vendor_stockout 主頁
   group: monitor · uses ewoooc-tokens-v2-alias
   ============================================================ */

.vendor-v2-stack {
  display: grid;
  gap: 24px;
}

.vendor-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.8fr);
  gap: 12px;
}

.vendor-hero-panel,
.vendor-card,
.vendor-table-card {
  background: var(--momo-bg-surface);
  border: 1px solid var(--momo-border-light);
  border-radius: 8px;
}

.vendor-hero-panel {
  display: flex;
  min-height: 228px;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
}

.vendor-eyebrow {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  padding: 4px 10px;
  color: var(--momo-accent-strong);
  background: var(--momo-accent-soft);
  border-radius: var(--momo-radius-pill);
  font-size: 11px;
  font-weight: 800;
}

.vendor-title {
  margin: 0;
  color: var(--momo-text-primary);
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.12;
}

.vendor-subtitle {
  max-width: 680px;
  margin: 10px 0 0;
  color: var(--momo-text-secondary);
  font-size: 14px;
  line-height: 1.8;
}

.vendor-actions {
  display: flex;
  gap: 8px;
  margin-top: 22px;
  flex-wrap: wrap;
}

.vendor-action {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 8px 14px;
  color: var(--momo-text-primary);
  background: var(--momo-bg-paper);
  border: 1px solid var(--momo-border-light);
  border-radius: 4px;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  transition: var(--momo-transition-base);
}

.vendor-action:hover {
  color: var(--momo-text-primary);
  border-color: var(--momo-border-strong);
  transform: translateY(-1px);
}

.vendor-action.is-primary {
  color: var(--momo-text-inverse);
  background: var(--momo-ink);
  border-color: var(--momo-ink);
}

.vendor-pulse {
  display: grid;
  align-content: stretch;
  padding: 18px;
  background: var(--momo-ink);
  border: 1px solid var(--momo-ink);
  border-radius: 8px;
}

.vendor-pulse-label {
  color: rgba(250, 247, 240, 0.62);
  font-size: 11px;
  font-weight: 800;
}

.vendor-pulse-value {
  margin-top: 8px;
  color: var(--momo-text-inverse);
  font-size: 34px;
  font-weight: 800;
  line-height: 1;
}

.vendor-pulse-meta {
  margin-top: 12px;
  color: rgba(250, 247, 240, 0.7);
  font-size: 12px;
  line-height: 1.7;
}

.vendor-kpi-grid,
.vendor-flow-grid {
  display: grid;
  gap: 12px;
}

.vendor-kpi-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.vendor-flow-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }

.vendor-card { padding: 18px; }

.vendor-kpi-label,
.vendor-card-label {
  color: var(--momo-text-secondary);
  font-size: 11px;
  font-weight: 800;
}

.vendor-kpi-value {
  margin-top: 8px;
  color: var(--momo-text-primary);
  font-size: 30px;
  font-weight: 800;
  line-height: 1;
}

.vendor-kpi-sub {
  margin-top: 8px;
  color: var(--momo-text-tertiary);
  font-size: 12px;
}

.vendor-kpi-value.is-danger { color: var(--momo-danger); }
.vendor-kpi-value.is-success { color: var(--momo-success); }

.vendor-section-label {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 12px;
}

.vendor-section-label .num {
  color: var(--momo-text-tertiary);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.vendor-section-label .title {
  color: var(--momo-text-primary);
  font-size: 13px;
  font-weight: 800;
}

.vendor-flow-card {
  display: flex;
  min-height: 138px;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px;
  color: var(--momo-text-primary);
  background: var(--momo-bg-surface);
  border: 1px solid var(--momo-border-light);
  border-radius: 8px;
  text-decoration: none;
  transition: var(--momo-transition-base);
}

.vendor-flow-card:hover {
  color: var(--momo-text-primary);
  border-color: var(--momo-border-strong);
  transform: translateY(-1px);
}

.vendor-flow-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  color: var(--momo-accent-strong);
  background: var(--momo-accent-soft);
  border-radius: 6px;
}

.vendor-flow-title {
  margin-top: 14px;
  font-size: 14px;
  font-weight: 800;
}

.vendor-flow-meta {
  margin-top: 4px;
  color: var(--momo-text-tertiary);
  font-size: 11px;
  line-height: 1.5;
}

.vendor-table-card { overflow: hidden; }

.vendor-table-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--momo-border-light);
}

.vendor-table-title {
  color: var(--momo-text-primary);
  font-size: 13px;
  font-weight: 800;
}

.vendor-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
}

.vendor-summary-item {
  min-height: 120px;
  padding: 18px;
  border-right: 1px solid var(--momo-border-light);
}

.vendor-summary-item:last-child { border-right: 0; }

.vendor-summary-title {
  margin-top: 8px;
  color: var(--momo-text-primary);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.4;
}

.vendor-summary-meta {
  margin-top: 8px;
  color: var(--momo-text-secondary);
  font-size: 12px;
  line-height: 1.7;
}

.vendor-empty {
  padding: 28px;
  color: var(--momo-text-secondary);
  background: var(--momo-bg-paper);
  border-top: 1px solid var(--momo-border-light);
  font-size: 13px;
  text-align: center;
}

@media (max-width: 1180px) {
  .vendor-hero,
  .vendor-kpi-grid,
  .vendor-flow-grid,
  .vendor-summary-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .vendor-v2-stack {
    gap: 16px;
  }

  .vendor-hero,
  .vendor-summary-grid {
    grid-template-columns: 1fr;
  }

  .vendor-hero-panel {
    min-height: auto;
    padding: 16px;
  }

  .vendor-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 16px;
  }

  .vendor-action {
    justify-content: center;
    min-height: 36px;
    padding: 8px 10px;
  }

  .vendor-action:nth-child(3) {
    grid-column: 1 / -1;
  }

  .vendor-pulse {
    padding: 14px 16px;
  }

  .vendor-pulse-value {
    margin-top: 6px;
    font-size: 26px;
  }

  .vendor-pulse-meta {
    margin-top: 8px;
    line-height: 1.55;
  }

  .vendor-kpi-grid,
  .vendor-flow-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .vendor-card {
    min-width: 0;
    padding: 12px;
  }

  .vendor-kpi-value {
    margin-top: 6px;
    font-size: 22px;
  }

  .vendor-kpi-sub {
    margin-top: 6px;
    font-size: 10px;
  }

  .vendor-flow-card {
    min-height: 108px;
    padding: 12px;
  }

  .vendor-flow-card:last-child {
    grid-column: 1 / -1;
  }

  .vendor-flow-icon {
    width: 30px;
    height: 30px;
  }

  .vendor-flow-title {
    margin-top: 10px;
    font-size: 13px;
  }

  .vendor-table-head {
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
  }

  .vendor-title { font-size: 28px; }

  .vendor-summary-item {
    min-height: auto;
    padding: 14px;
    border-right: 0;
    border-bottom: 1px solid var(--momo-border-light);
  }
}

@media (max-width: 420px) {
  .vendor-title {
    font-size: 26px;
  }

  .vendor-subtitle {
    font-size: 13px;
    line-height: 1.65;
  }

  .vendor-card,
  .vendor-flow-card {
    padding: 10px;
  }
}
