/* ===== AppMock — anonymized product UI ===== */
.am {
  --am-bg: #f5f7fb;
  --am-side: #ffffff;
  --am-line: #e8ecf3;
  --am-line-2: #f0f2f7;
  --am-text: #1f2541;
  --am-text-2: #5f6788;
  --am-text-3: #8b92ac;
  --am-brand: #3361ff;
  --am-brand-soft: #e7eeff;
  --am-green: #10b981;

  width: 1000px;
  background: var(--am-bg);
  color: var(--am-text);
  font-family: "PingFang SC", "Microsoft YaHei", var(--font-sans);
  font-size: 13px;
  border-radius: 12px;
  overflow: hidden;
  transform-origin: top left;
}

/* chrome */
.am-chrome {
  display: flex; align-items: center; gap: 6px;
  padding: 10px 14px;
  background: #eff1f6;
  border-bottom: 1px solid var(--am-line);
  position: relative;
}
.am-chrome .am-dot {
  width: 11px; height: 11px; border-radius: 50%;
}
.am-chrome .am-dot.r { background: #ff5f56; }
.am-chrome .am-dot.y { background: #ffbd2e; }
.am-chrome .am-dot.g { background: #27c93f; }
.am-chrome .am-title {
  position: absolute;
  left: 50%; transform: translateX(-50%);
  font-size: 12px; color: var(--am-text-3); font-weight: 500;
}

.am-body {
  display: grid;
  grid-template-columns: 200px 1fr;
}

/* sidebar */
.am-side {
  background: var(--am-side);
  border-right: 1px solid var(--am-line);
  padding: 16px 14px;
  display: flex; flex-direction: column;
  gap: 14px;
}
.am-brand {
  display: flex; align-items: center; gap: 10px;
  padding: 4px 2px;
}
.am-brand img { width: 28px; height: 28px; border-radius: 7px; }
.am-brand-n { font-size: 13px; font-weight: 600; color: var(--am-text); }
.am-brand-v { font-size: 10px; color: var(--am-text-3); font-family: var(--font-mono); }

.am-new {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 14px;
  background: var(--am-brand);
  color: white;
  border: none;
  border-radius: 8px;
  font: inherit;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  box-shadow: 0 4px 14px -4px rgba(51, 97, 255, 0.5);
}
.am-new-caret { font-size: 9px; opacity: 0.8; margin-left: 2px; }

.am-menu-g { display: flex; flex-direction: column; gap: 2px; margin-top: 6px; }
.am-menu-h {
  font-size: 10px;
  color: var(--am-text-3);
  letter-spacing: 0.08em;
  padding: 4px 10px;
  margin-bottom: 2px;
}
.am-menu-i {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px;
  border-radius: 6px;
  font-size: 13px;
  color: var(--am-text-2);
  cursor: pointer;
}
.am-menu-i .am-ic { color: var(--am-text-3); }
.am-menu-i.on {
  background: var(--am-brand-soft);
  color: var(--am-brand);
  font-weight: 600;
}
.am-menu-i.on .am-ic { color: var(--am-brand); }

.am-user {
  margin-top: auto;
  display: flex; align-items: center; gap: 10px;
  padding: 10px 8px;
  background: #fafbfe;
  border: 1px solid var(--am-line);
  border-radius: 8px;
}
.am-u-av {
  width: 28px; height: 28px; border-radius: 50%;
  background: linear-gradient(135deg, #ffb547, #ff7847);
  color: white;
  font-size: 12px; font-weight: 600;
  display: grid; place-items: center;
}
.am-u-n { font-size: 12px; font-weight: 600; color: var(--am-text); }
.am-u-id { font-size: 10px; color: var(--am-text-3); font-family: var(--font-mono); }

/* main */
.am-main {
  display: flex; flex-direction: column;
  background: var(--am-bg);
}
.am-head {
  padding: 20px 24px 12px;
  background: var(--am-side);
  border-bottom: 1px solid var(--am-line);
}
.am-title-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
}
.am-head h2 {
  color: var(--am-text);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  display: flex; align-items: center; gap: 10px;
}
.am-count {
  font-size: 12px;
  font-weight: 500;
  color: var(--am-text-3);
}
.am-sub { color: var(--am-text-3); font-size: 12px; margin-top: 6px; }

.am-actions {
  display: flex; align-items: center; gap: 8px;
  flex-wrap: wrap;
}
.am-check {
  display: flex; align-items: center; gap: 6px;
  font-size: 12px;
  color: var(--am-text-2);
}
.am-check input {
  width: 14px; height: 14px; accent-color: var(--am-brand);
}
.am-search {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  background: #f5f7fb;
  border: 1px solid var(--am-line);
  border-radius: 6px;
  color: var(--am-text-3);
  font-size: 12px;
  width: 180px;
}
.am-btn {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 6px 12px;
  background: #f5f7fb;
  border: 1px solid var(--am-line);
  color: var(--am-text-2);
  border-radius: 6px;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.am-btn.primary {
  background: var(--am-brand);
  border-color: var(--am-brand);
  color: white;
}
.am-view-switch {
  display: inline-flex;
  border: 1px solid var(--am-line);
  border-radius: 6px;
  overflow: hidden;
}
.am-view-switch button {
  background: #f5f7fb;
  border: none;
  padding: 7px 10px;
  color: var(--am-text-3);
  cursor: pointer;
}
.am-view-switch button.on {
  background: var(--am-brand-soft);
  color: var(--am-brand);
}

.am-tabs {
  display: flex; gap: 6px;
  margin-top: 16px;
  margin-bottom: 4px;
}
.am-tab {
  padding: 6px 14px;
  background: #f5f7fb;
  border-radius: 6px;
  font-size: 12px;
  color: var(--am-text-2);
  display: flex; align-items: center; gap: 6px;
}
.am-tab.on {
  background: var(--am-brand);
  color: white;
  font-weight: 500;
}
.am-tab.on b { background: rgba(255,255,255,0.25); }
.am-tab b {
  background: #eaeef6;
  color: inherit;
  padding: 1px 7px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 11px;
  font-family: var(--font-mono);
}
.am-tab.add {
  background: transparent;
  border: 1px dashed var(--am-line);
  color: var(--am-text-3);
}

/* table */
.am-table {
  background: var(--am-side);
  margin: 12px 16px 0;
  border: 1px solid var(--am-line);
  border-radius: 8px;
  overflow: hidden;
}
.am-thead, .am-row {
  display: grid;
  grid-template-columns:
    32px   /* checkbox */
    36px   /* # */
    1.5fr  /* name */
    0.9fr  /* tag */
    1.3fr  /* ip */
    0.55fr /* sys */
    0.75fr /* status */
    0.55fr /* note */
    0.75fr /* assigned */
    0.65fr /* created */
    0.85fr /* opened */
    130px; /* action — fixed so launch + more fit */
  align-items: center;
  padding: 0 14px;
  gap: 10px;
}
.col-act {
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: flex-start;
  white-space: nowrap;
}
.am-thead {
  padding: 10px 14px;
  background: #fafbfe;
  border-bottom: 1px solid var(--am-line);
  font-size: 11px;
  color: var(--am-text-3);
  font-weight: 500;
}
.am-thead input, .am-row input {
  width: 14px; height: 14px; accent-color: var(--am-brand);
}
.am-row {
  padding: 12px 14px;
  font-size: 12px;
  color: var(--am-text-2);
  border-bottom: 1px solid var(--am-line-2);
}
.am-row:last-child { border-bottom: none; }
.am-row.on {
  background: var(--am-brand-soft);
}
.am-row.on .am-row-name { color: var(--am-brand); font-weight: 600; }
.am-row.on .am-ip { color: var(--am-brand); }

.am-num {
  display: grid; place-items: center;
  width: 24px; height: 24px;
  border-radius: 50%;
  color: white;
  font-size: 11px;
  font-weight: 600;
  font-family: var(--font-mono);
}
.am-row-name { color: var(--am-text); font-weight: 500; }
.am-row-sub { color: var(--am-text-3); font-size: 10px; margin-left: 6px; }
.am-chip {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 500;
}
.am-chip.blue { background: var(--am-brand-soft); color: var(--am-brand); }
.am-chip.blue-dark {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--am-brand);
  color: white;
  align-items: center; justify-content: center;
  padding: 0;
}
.am-muted { color: #c6cbd9; }
.am-ip { color: #10a37f; font-family: var(--font-mono); font-size: 11px; font-weight: 500; }
.am-ip-loc { color: var(--am-text-3); font-size: 10px; margin-top: 1px; }
.am-status { display: inline-flex; align-items: center; gap: 5px; color: var(--am-text-2); }
.am-st-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #c6cbd9;
}
.am-launch {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 5px 12px;
  background: white;
  border: 1px solid var(--am-green);
  color: var(--am-green);
  border-radius: 5px;
  font: inherit;
  font-size: 11px;
  font-weight: 500;
  cursor: pointer;
}
.am-more-btn {
  width: 26px; height: 26px;
  display: inline-grid; place-items: center;
  background: white;
  border: 1px solid var(--am-line);
  border-radius: 5px;
  color: var(--am-text-3);
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: all 160ms;
}
.am-more-btn:hover {
  border-color: var(--am-brand);
  color: var(--am-brand);
}

.am-foot {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 24px;
  margin-top: auto;
  color: var(--am-text-3);
  font-size: 12px;
}
.am-page { display: flex; gap: 4px; }
.am-pg-btn {
  width: 28px; height: 28px;
  display: grid; place-items: center;
  background: white;
  border: 1px solid var(--am-line);
  border-radius: 4px;
  font-size: 12px;
  color: var(--am-text-2);
}
.am-pg-btn.on {
  background: var(--am-brand);
  border-color: var(--am-brand);
  color: white;
}

/* Mount inside .hv-shot — fill its width, JS-scaled via ResizeObserver.
   AppMock native size is 1000 × 940 */
.hv-shot {
  padding: 0;
  aspect-ratio: 1000 / 940;
}
.am-wrap {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.hv-shot .am {
  width: 1000px;
  transform-origin: top left;
  /* transform set by JS */
}
