:root {
  color-scheme: light;
  color: #182d46;
  background: #eff3f7;
  font:
    15px/1.6 "Microsoft YaHei UI",
    "PingFang SC",
    system-ui,
    sans-serif;
  --ink: #182d46;
  --muted: #52677f;
  --blue: #135ac6;
  --line: #d9e3ef;
  --surface: #fff;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  overflow-wrap: anywhere;
}
header {
  background: #142f55;
  color: white;
  min-height: 68px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px max(18px, calc((100% - 1200px) / 2));
}
.identity {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: 18px;
}
.identity b {
  font-size: 22px;
  letter-spacing: 0.08em;
}
.identity span,
#account-name {
  color: #dae7fb;
  font-size: 13px;
}
main {
  max-width: 1240px;
  margin: auto;
  padding: 28px 22px 60px;
}
h1,
h2,
h3,
p {
  margin: 0 0 10px;
}
h1 {
  font-size: clamp(24px, 4vw, 32px);
  line-height: 1.35;
}
h2 {
  font-size: 20px;
}
h3 {
  font-size: 16px;
  margin-top: 22px;
}
p,
small {
  color: var(--muted);
}
a {
  color: #134f9c;
  text-underline-offset: 0.18em;
}
:focus-visible {
  outline: 3px solid #4081dd;
  outline-offset: 2px;
}
button,
input,
select,
textarea {
  font: inherit;
  max-width: 100%;
  min-width: 0;
}
button {
  border: 0;
  border-radius: 7px;
  background: var(--blue);
  color: white;
  padding: 9px 16px;
  min-height: 42px;
  cursor: pointer;
}
button:disabled {
  opacity: 0.55;
  cursor: default;
}
.secondary {
  background: #e8eff8;
  color: #23466c;
}
nav {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 8px;
  border-radius: 12px;
  margin-bottom: 24px;
}
nav button {
  background: transparent;
  color: var(--muted);
}
nav .selected {
  color: white;
  background: #174c93;
  font-weight: 600;
}
section {
  min-width: 0;
}
.title,
.line,
.actions,
.record-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
}
.title,
.line {
  justify-content: space-between;
}
.title {
  margin-bottom: 18px;
}
.actions a {
  padding: 7px 2px;
}
.surface,
.banner,
form {
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: clamp(14px, 2.5vw, 24px);
  margin-bottom: 16px;
}
form form {
  margin-bottom: 0;
}
label {
  display: block;
  font-weight: 600;
  margin: 12px 0;
  min-width: 0;
}
input,
select,
textarea {
  display: block;
  width: 100%;
  margin-top: 5px;
  padding: 9px 11px;
  border: 1px solid #aebed1;
  border-radius: 7px;
  color: var(--ink);
  background: #fbfdff;
}
input[type="file"] {
  width: 100%;
}
textarea {
  min-height: 90px;
  resize: vertical;
}
.check {
  display: flex;
  align-items: start;
  gap: 8px;
  font-weight: 400;
}
.check input {
  width: auto;
  margin: 5px 0 0;
  flex: 0 0 auto;
}
.pair,
.editor-layout,
.import-layout,
.selection-grid {
  display: grid;
  gap: 16px;
}
.pair {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.editor-layout {
  grid-template-columns: minmax(0, 1fr) minmax(0, 430px);
}
.catalog-intro {
  padding: clamp(18px, 3.5vw, 38px);
  border-radius: 16px;
  background: linear-gradient(115deg, #132f54, #1d5592);
  color: white;
}
.catalog-intro .title {
  margin-bottom: 12px;
}
.catalog-intro h1 {
  margin: 0;
}
.catalog-intro .actions button {
  border: 1px solid #b9cff0;
}
.catalog-intro input {
  max-width: 650px;
  min-height: 48px;
}
.catalog-section {
  margin-top: 24px;
}
.catalog-section > h2 {
  margin-bottom: 10px;
}
.catalog-divider {
  margin-bottom: 12px;
}
.catalog-divider h2,
.catalog-divider p {
  margin-bottom: 0;
}
.catalog-divider select {
  width: min(180px, 100%);
  margin: 0;
}
.scene-picker,
#product-picker {
  display: grid;
  gap: 12px;
}
.scene-picker {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
#product-picker {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.scene-option,
.product-option {
  display: flex;
  flex-direction: column;
  text-align: left;
  width: 100%;
  min-width: 0;
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 0;
  overflow: hidden;
}
.scene-option:hover,
.product-option:hover {
  border-color: #5f88c1;
}
.scene-option img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.scene-option strong {
  padding: 8px 12px;
}
.product-card-photo {
  width: 100%;
  min-height: 110px;
  height: clamp(110px, 15vw, 164px);
  display: grid;
  place-items: center;
  background: #f7fafd;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
}
.product-card-photo img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
}
.product-card-copy {
  display: grid;
  gap: 4px;
  padding: 10px 12px 13px;
}
.product-card-copy strong {
  line-height: 1.35;
}
.catalog-back {
  margin-bottom: 14px;
}
.detail-column {
  max-width: 980px;
  margin: auto;
}
.scene-lead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.scene-lead img {
  width: min(32%, 224px);
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 8px;
}
.inline-link {
  background: transparent;
  color: #134f9c;
  padding: 3px 7px;
  text-decoration: underline;
  text-underline-offset: 0.18em;
}
.method-details {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 13px;
}
.method-details[open] summary {
  margin-bottom: 8px;
}
.method-details ol {
  padding-inline-start: 24px;
}
.demo-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  background: #fff0cc;
  color: #714e09;
  font-size: 13px;
}
.product-lead {
  display: flex;
  gap: 18px;
  align-items: center;
}
.product-lead img {
  width: 112px;
  height: 108px;
  object-fit: contain;
  flex: 0 0 auto;
  background: #f5f8fd;
  border-radius: 9px;
}
.product-lead span {
  color: #18578f;
  font-size: 13px;
}
.product-lead h2 {
  font-size: clamp(21px, 4vw, 30px);
  line-height: 1.35;
  margin: 4px 0;
}
.stock-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0;
}
.stock-pills span {
  color: #295675;
  background: #eaf3fc;
  padding: 6px 11px;
  border-radius: 7px;
}
.facts {
  display: grid;
  grid-template-columns: minmax(95px, 1fr) minmax(0, 2fr);
  gap: 0 14px;
}
.facts dt,
.facts dd {
  padding: 7px 0;
  border-bottom: 1px solid #ebeff5;
  margin: 0;
}
.facts dt {
  color: var(--muted);
}
.spec-editor {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}
.selection-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
fieldset {
  min-width: 0;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.media-entry,
.import-photo {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  margin: 8px 0;
}
.media-entry img,
.import-photo img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: 108px;
  margin-bottom: 6px;
}
.media-entry button {
  margin-left: 8px;
}
details {
  margin: 14px 0;
}
summary {
  cursor: pointer;
  font-weight: 600;
}
details li {
  margin: 6px 0;
}
.history-line {
  border-bottom: 1px solid var(--line);
  padding: 9px 0;
  margin: 0;
}
.table-scroll {
  overflow-x: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
}
td,
th {
  border-bottom: 1px solid var(--line);
  text-align: left;
  padding: 8px;
}
#banner-list img,
#banner-list video {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 8px;
}
#media-preview img,
#media-preview video,
#poster-preview {
  max-width: 100%;
  max-height: 210px;
}
.badge {
  background: #eaf3ff;
  color: #154e8d;
  padding: 4px 7px;
  border-radius: 4px;
}
.hint,
.result {
  font-size: 13px;
}
#login {
  max-width: 470px;
  margin: 40px auto;
}
#status:not(:empty) {
  position: fixed;
  z-index: 5;
  bottom: 12px;
  right: 12px;
  width: max-content;
  max-width: calc(100% - 24px);
  max-height: 25vh;
  overflow: auto;
  background: #183a65;
  color: white;
  padding: 10px 15px;
  border-radius: 8px;
}
#editor-status {
  color: #8d3d2b;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 0;
  width: min(980px, calc(100% - 22px));
  max-height: 92vh;
  color: var(--ink);
}
dialog::backdrop {
  background: #102641aa;
}
dialog form {
  border: 0;
  margin: 0;
}
.import-layout {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.import-layout pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: inherit;
  max-height: 44vh;
  overflow: auto;
  background: #f2f6fc;
  padding: 12px;
  border-radius: 7px;
}
[hidden] {
  display: none !important;
}
@media (max-width: 850px) {
  main {
    padding: 18px 14px 60px;
  }
  .editor-layout {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 720px) {
  .import-layout {
    grid-template-columns: 1fr;
  }
  .scene-picker {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  #product-picker {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  nav button {
    padding: 7px 10px;
  }
}
@media (max-width: 440px) {
  .pair,
  .selection-grid {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .scene-picker {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .scene-option img {
    aspect-ratio: 2 / 1;
  }
  .product-lead img {
    width: 70px;
    height: 75px;
  }
  .spec-editor {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
  .spec-editor button {
    justify-self: start;
  }
}

.secondary-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 0 14px;
}
.secondary-nav [aria-pressed="true"],
.admission-option[aria-pressed="true"] {
  background: #dceafb;
  color: #123c72;
  box-shadow: inset 0 0 0 1px #5e87c1;
}
#admission-work > input {
  max-width: 480px;
  margin-bottom: 16px;
}
.admission-layout {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) minmax(0, 2.1fr);
  align-items: start;
  gap: 16px;
}
.admission-list {
  display: grid;
  gap: 8px;
}
.admission-option {
  display: block;
  width: 100%;
  text-align: left;
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
}
.admission-option small {
  display: block;
}
.ai-review,
.demo-stock-note {
  background: #eaf3fe;
  color: #234572;
  border-radius: 9px;
  padding: 14px;
  margin: 12px 0;
}
.ai-review > p {
  margin: 8px 0 0;
}
@media (max-width: 720px) {
  .admission-layout {
    grid-template-columns: 1fr;
  }
  .secondary-nav button {
    padding: 6px 10px;
  }
}
