/* 吉祥物页：满屏一页收齐，沿用宣传页/工牌的顶栏与面板气质 */

.subnav {
  flex: 0 0 auto;
  display: flex;
  align-items: stretch;
  gap: 8px;
  height: 42px;
  padding: 6px 20px 0;
  background: var(--brand-navy);
}

.subnav-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  min-width: 96px;
  padding: 0 16px;
  border-radius: 8px 8px 0 0;
  cursor: pointer;
}

.subnav-btn:hover { background: rgba(255, 255, 255, 0.14); }

.subnav-btn.is-on {
  background: var(--brand-bg);
  color: var(--brand-navy);
  font-weight: 700;
  box-shadow: inset 0 3px 0 var(--brand-gold);
}

#app-root { background: var(--brand-bg); }

.view-collect[hidden],
.view-design[hidden] { display: none !important; }

.view-design,
.view-collect {
  flex: 1;
  min-height: 0;
}

.stage-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 32px;
  margin-bottom: 6px;
}

.stage-spacer { flex: 1; }

.stage-toolbar .hint {
  margin: 0;
  font-size: 12px;
  color: #6b645c;
  max-width: 70%;
  text-align: right;
}

.stage {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  background: #ece7dc;
  border: 1px solid #e6e0d6;
  border-radius: 10px;
}

.board {
  height: 100%;
  display: grid;
  grid-template-columns: 0.9fr 0.7fr 1.35fr 1.05fr;
  grid-template-rows: minmax(0, 1.15fr) minmax(0, 0.95fr) minmax(0, 0.7fr);
  grid-template-areas:
    "hero reverse badge card"
    "hero avatar badge cover"
    "banner banner badge cover";
  gap: 8px;
  padding: 8px;
}

.tile {
  margin: 0;
  min-width: 0;
  min-height: 0;
  background: #fffcf7;
  border: 1px solid #e6e0d6;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.tile canvas {
  flex: 1;
  min-height: 0;
  width: 100%;
  display: block;
}

.tile figcaption {
  flex: 0 0 auto;
  text-align: center;
  font-size: 12px;
  color: var(--brand-navy);
  padding: 3px 6px 5px;
  letter-spacing: 0.04em;
}

.tile-hero { grid-area: hero; }
.tile-reverse { grid-area: reverse; }
.tile-avatar { grid-area: avatar; }
.tile-badge { grid-area: badge; }
.tile-card { grid-area: card; }
.tile-cover { grid-area: cover; }
.tile-banner { grid-area: banner; }

.sample-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 6px;
}

.sample-opt {
  appearance: none;
  border: 1px solid #d9d2c6;
  background: #fff;
  border-radius: 8px;
  padding: 4px 4px 6px;
  cursor: pointer;
  color: var(--brand-navy);
  text-align: center;
}

.sample-opt img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  background: var(--brand-bg);
  border-radius: 6px;
}

.sample-opt span {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  font-weight: 600;
}

.sample-opt em {
  display: block;
  font-style: normal;
  font-size: 10px;
  color: #8a837a;
}

.sample-opt.is-on {
  border-color: var(--brand-navy);
  box-shadow: inset 0 0 0 1px var(--brand-navy);
  background: #f7f4ee;
}

.sample-opt.is-official em { color: #133F99; font-weight: 600; }

.sample-row.with-official { grid-template-columns: repeat(4, 1fr); }

.edit-preview-wrap {
  margin: 6px auto 8px;
  max-width: 188px;
  border: 1px solid #e6e0d6;
  border-radius: 8px;
  background:
    linear-gradient(45deg, #efebe3 25%, transparent 25%) 0 0 / 16px 16px,
    linear-gradient(45deg, transparent 75%, #efebe3 75%) 0 0 / 16px 16px,
    linear-gradient(45deg, transparent 75%, #efebe3 75%) 8px 8px / 16px 16px,
    linear-gradient(45deg, #efebe3 25%, transparent 25%) 8px 8px / 16px 16px,
    #fff;
  overflow: hidden;
  cursor: grab;
}

.edit-preview-wrap.is-drag { cursor: grabbing; }

#edit-canvas {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  touch-action: none;
}

.asset-slider {
  display: grid;
  grid-template-columns: 42px 1fr 42px;
  gap: 8px;
  align-items: center;
  font-size: 12px;
  color: #3f3a36;
  margin: 4px 0;
}

.asset-slider input[type="range"] { width: 100%; }

.asset-slider em {
  font-style: normal;
  text-align: right;
  color: #6b645c;
}

.chip-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 6px 0 4px;
}

.chip {
  border: 1px solid #d9d2c6;
  background: #fffcf7;
  border-radius: 8px;
  padding: 6px 10px;
  color: var(--brand-navy);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
}

.chip.is-on {
  background: var(--brand-navy);
  color: #fff;
  border-color: var(--brand-navy);
}

.toggle-row {
  display: flex;
  gap: 14px;
  margin: 6px 0 2px;
  font-size: 13px;
  color: #3f3a36;
}

.check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  white-space: nowrap;
}

.btn-row.single { grid-template-columns: 1fr; }

.hint { margin: 6px 0 0; font-size: 12px; color: #6b645c; line-height: 1.5; }

.status { margin: 8px 0 0; font-size: 12px; color: var(--brand-navy); min-height: 1.2em; }
.status.is-error { color: #b42318; }

.notice {
  margin: 8px 0 0;
  padding: 8px 10px;
  border-radius: 8px;
  background: #fff4e5;
  border: 1px solid #f3d5a3;
  color: #6a4b12;
  font-size: 13px;
  line-height: 1.55;
}

.notice.is-ok {
  background: #eef6ef;
  border-color: #c9e0cc;
  color: #1c4c2c;
}

.submit-preview {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 8px 0 0;
}

.submit-preview[hidden] { display: none !important; }

.submit-preview img {
  width: 72px;
  height: 72px;
  object-fit: contain;
  border: 1px solid #e6e0d6;
  border-radius: 8px;
  background: #fff;
}

.link {
  border: 0;
  background: transparent;
  color: var(--brand-navy);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  padding: 0;
}

.gallery-stage { overflow: auto; }

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  padding: 10px;
  align-content: start;
}

.gallery-empty {
  grid-column: 1 / -1;
  margin: 40px 16px;
  text-align: center;
  color: #6b645c;
  font-size: 14px;
}

.g-card {
  background: #fffcf7;
  border: 1px solid #e6e0d6;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.g-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  background:
    linear-gradient(45deg, #efebe3 25%, transparent 25%) 0 0 / 16px 16px,
    linear-gradient(45deg, transparent 75%, #efebe3 75%) 0 0 / 16px 16px,
    #fff;
}

.g-card .g-body { padding: 8px 10px 10px; display: flex; flex-direction: column; gap: 4px; }
.g-card .g-author { font-size: 13px; font-weight: 600; color: var(--brand-navy); }
.g-card .g-meta { font-size: 11px; color: #8a837a; }
.g-card .g-note { font-size: 12px; color: #3f3a36; line-height: 1.45; }
.g-badge {
  display: inline-block;
  align-self: start;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--brand-navy);
  background: var(--brand-gold);
  border-radius: 4px;
  padding: 1px 6px;
}

.g-card .btn { margin-top: 6px; }

.modal[hidden] { display: none !important; }
.modal {
  position: fixed;
  inset: 0;
  background: rgba(10, 46, 93, 0.28);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 20;
}
.modal-card {
  width: min(420px, 100%);
  max-height: min(70vh, 560px);
  overflow: auto;
  background: #fffcf7;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 12px 40px rgba(10, 46, 93, 0.18);
}
.file-list { display: flex; flex-direction: column; gap: 6px; margin: 12px 0; }
.file-item {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  text-align: left;
  border: 1px solid #e6e0d6;
  background: #fff;
  border-radius: 8px;
  padding: 8px 10px;
  cursor: pointer;
  font: inherit;
  color: inherit;
}
.file-item:hover { border-color: var(--brand-navy); }
.file-item strong { flex: 1; font-size: 13px; }
.file-item span { font-size: 11px; color: #8a837a; }
.file-item .link { flex: 0 0 auto; }

@media (max-width: 1080px) {
  .layout { grid-template-columns: minmax(260px, 320px) minmax(0, 1fr); }
  .board {
    grid-template-columns: 1fr 1fr 1.2fr;
    grid-template-areas:
      "hero badge card"
      "reverse badge cover"
      "avatar banner banner";
  }
}
