@import url("https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Grenze+Gotisch:wght@400;500;700&family=Hina+Mincho&family=Manufacturing+Consent&family=Noto+Sans+SC:wght@400;500;700&family=Noto+Serif+SC:wght@400;600;700&family=Pirata+One&family=UnifrakturCook:wght@700&family=Yuji+Mai&family=Yuji+Syuku&display=swap");
@import url("/font/english-google/result.css");
@import url("/font/bakudai/result.css");
@import url("/font/Aahoudihei/result.css");
@import url("/font/aosagi/result.css");
@import url("/font/CooperZhengKai-1/result.css");
@import url("/font/CorpSrcWinSong-/result.css");
@import url("/font/FZG_CN/result.css");
@import url("/font/LXGWZhiSongCL/result.css");
@import url("/font/MonuTitl-0/result.css");
@import url("/font/MonuYueDong-1/result.css");
@import url("/font/kesi-yan/result.css");
@import url("/font/zt-qingya/result.css");
@import url("/font/yusiyuan-yanhuang/result.css");
@import url("/font/zt-ziyou/result.css");
@import url("/font/aidian-yahei-condensed/result.css");
@import url("/font/taiwan-std-li/result.css");
@import url("/font/zhaohua-typewriter/zhaohua-typewriter/result.css");
@import url("/font/zhaohua-title-a/result.css");
@import url("/font/huiwen-fangsong-v1/result.css");
@import url("/font/huiwen-mincho/result.css");
@import url("/font/huiwen-zhengkai-v1/result.css");
@import url("/font/kugel-gothic/result.css");
@import url("/font/hengshan-maobi/alias-result.css");
@import url("/font/aoyagi-reisho/alias-result.css");
@import url("/font/xiangcui-song-w40/xiangcui-song-w40/result.css");
@import url("/font/xiangcui-song-w15/xiangcui-song-w15/result.css");
@import url("/font/banana-plus/result.css");

:root {
  --editor-ink: #302922;
  --editor-ink-soft: #7d7166;
  --editor-ink-faint: #a09488;
  --editor-paper-ui: #f7f2eb;
  --editor-paper-preview: #f1e7d6;
  --editor-warm-panel: #f5efe7;
  --editor-warm-panel-deep: #ece2d6;
  --editor-rule: rgba(132, 108, 84, 0.54);
  --editor-rule-soft: rgba(132, 108, 84, 0.18);
  --editor-accent: #c97953;
  --editor-accent-deep: #a95f3d;
  --editor-accent-soft: rgba(201, 121, 83, 0.12);
  --editor-danger: #9b5b46;
  --editor-grid: rgba(72, 54, 38, 0.16);
  --editor-grid-strong: rgba(72, 54, 38, 0.28);
  --editor-shadow: 0 18px 38px rgba(80, 52, 32, 0.1);
  --editor-region: rgba(67, 46, 27, 0.1);
  --editor-region-selected: rgba(201, 121, 83, 0.11);
  --editor-valid: #5a7a46;
  --masthead-title-font: "Bakudai-Regular", "ZhaohuaMinA", "Noto Serif SC", "Songti SC", "STSong", serif;
  --masthead-latin-font: "Newsreader", "Cormorant Garamond", "Libre Baskerville", "Baskerville Old Face", "Times New Roman", serif;
  --masthead-meta-font: "ZhaohuaMinA", "Noto Serif SC", "Songti SC", "STSong", serif;
  --masthead-typewriter-font: "ZhaohuaTypeWriter Light", "Courier Prime", "Special Elite", "Courier New", monospace;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  color: var(--editor-ink);
  font-family: "Noto Sans SC", "Source Han Sans", "Noto Sans CJK SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 30%),
    linear-gradient(180deg, #f4efe8 0%, #ebe4da 100%);
}

html[data-app-mode="export-renderer"],
html[data-app-mode="export-renderer"] body {
  width: 720px;
  height: 1018px;
  min-height: 1018px;
  overflow: hidden;
  background: transparent;
}

body.editor-export-renderer {
  margin: 0;
  padding: 0;
}

body.is-booting {
  overflow: hidden;
}

.editor-loading-screen {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.7), transparent 42%),
    linear-gradient(180deg, rgba(248, 242, 233, 0.96), rgba(237, 228, 214, 0.96));
  backdrop-filter: blur(14px) saturate(118%);
  transition:
    opacity 260ms ease,
    visibility 260ms ease;
}

body:not(.is-booting) .editor-loading-screen {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

body.is-exporting .editor-loading-screen,
body.is-export-preview .editor-loading-screen {
  display: none !important;
}

.editor-loading-screen__card {
  width: min(100%, 32rem);
  display: grid;
  gap: 1rem;
  padding: 1.5rem 1.55rem;
  border: 1px solid rgba(132, 108, 84, 0.2);
  border-radius: 1.4rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 242, 235, 0.94));
  box-shadow:
    0 26px 54px rgba(80, 52, 32, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.74);
}

.editor-loading-screen__eyebrow {
  margin: 0;
  color: var(--editor-ink-soft);
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

.editor-loading-screen__card h2 {
  margin: -0.2rem 0 0;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-family: "Noto Serif SC", "Source Han Serif", "Noto Serif CJK SC", "Songti SC", serif;
  font-weight: 600;
}

.editor-loading-screen__status,
.editor-loading-screen__progress-value,
.editor-loading-screen__tip-text {
  margin: 0;
}

.editor-loading-screen__status {
  color: var(--editor-ink-soft);
  font-size: 0.95rem;
}

.editor-loading-screen__progress {
  position: relative;
  overflow: hidden;
  height: 0.78rem;
  border: 1px solid rgba(132, 108, 84, 0.14);
  border-radius: 999px;
  background: rgba(232, 224, 214, 0.84);
}

.editor-loading-screen__progress-bar {
  position: relative;
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(201, 121, 83, 0.84), rgba(162, 92, 62, 0.95));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4);
  transition: width 220ms ease;
}

.editor-loading-screen__progress-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      120deg,
      transparent 0%,
      rgba(255, 255, 255, 0.12) 22%,
      rgba(255, 255, 255, 0.36) 45%,
      rgba(255, 255, 255, 0.14) 68%,
      transparent 100%
    );
  animation: editor-loading-bar-sheen 1.5s linear infinite;
}

.editor-loading-screen__progress-value {
  color: var(--editor-ink-soft);
  font-size: 0.88rem;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.editor-loading-screen__tip-card {
  display: grid;
  gap: 0.36rem;
  padding: 0.95rem 1rem;
  border: 1px solid rgba(132, 108, 84, 0.12);
  border-radius: 1.1rem;
  background: rgba(252, 248, 243, 0.9);
}

.editor-loading-screen__tip-label {
  color: var(--editor-accent-deep);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.editor-loading-screen__tip-text {
  min-height: 2.8em;
  color: var(--editor-ink);
  line-height: 1.55;
}

@keyframes editor-loading-bar-sheen {
  from {
    transform: translateX(-100%);
  }

  to {
    transform: translateX(220%);
  }
}

@media (max-width: 640px) {
  .editor-loading-screen {
    padding: 1rem;
  }

  .editor-loading-screen__card {
    width: min(100%, 28rem);
    padding: 1.2rem 1.1rem;
    gap: 0.88rem;
    border-radius: 1.1rem;
  }

  .editor-loading-screen__tip-text {
    min-height: auto;
  }
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  padding: 0.64rem 0.94rem;
  border: 1px solid rgba(132, 108, 84, 0.22);
  background: rgba(255, 255, 255, 0.9);
  border-radius: 0.9rem;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition:
    background-color 120ms ease,
    border-color 120ms ease,
    color 120ms ease,
    box-shadow 120ms ease,
    transform 120ms ease;
}

button:hover {
  background: rgba(255, 253, 250, 0.98);
  border-color: rgba(132, 108, 84, 0.34);
}

button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid rgba(132, 108, 84, 0.18);
  background: rgba(255, 255, 255, 0.92);
  border-radius: 0.95rem;
  padding: 0.62rem 0.74rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
  transition:
    border-color 140ms ease,
    background-color 140ms ease,
    box-shadow 140ms ease;
}

textarea {
  min-height: 6.2rem;
  resize: vertical;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: none;
  border-color: rgba(169, 95, 61, 0.46);
  box-shadow:
    0 0 0 3px rgba(201, 121, 83, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.hidden {
  display: none !important;
}

.editor-nav-panel::-webkit-scrollbar,
.editor-panel::-webkit-scrollbar {
  width: 0.75rem;
}

.editor-nav-panel::-webkit-scrollbar-track,
.editor-panel::-webkit-scrollbar-track {
  background: transparent;
}

.editor-nav-panel::-webkit-scrollbar-thumb,
.editor-panel::-webkit-scrollbar-thumb {
  border: 0.22rem solid transparent;
  border-radius: 999px;
  background: rgba(160, 131, 104, 0.28);
  background-clip: padding-box;
}

.editor-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.editor-topbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  padding: 1rem 1.2rem 0.8rem;
  border-bottom: 3px double var(--editor-rule);
  background: linear-gradient(180deg, rgba(251, 252, 253, 0.98), rgba(240, 244, 247, 0.98));
  backdrop-filter: blur(16px) saturate(125%);
}

.editor-topbar__title h1,
.editor-stage-header h2 {
  margin: 0;
  font-family: "Noto Serif SC", "Source Han Serif", "Noto Serif CJK SC", "Songti SC", serif;
  font-weight: 600;
}

.editor-topbar__title h1 {
  font-size: clamp(1.28rem, 2vw, 1.8rem);
}

.editor-eyebrow {
  margin: 0 0 0.18rem;
  color: var(--editor-ink-soft);
  font-size: 0.75rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}

.editor-topbar__meta {
  display: flex;
  align-items: flex-end;
  gap: 1rem;
}

.editor-topbar__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 0.55rem;
}

.editor-topbar__actions button {
  white-space: nowrap;
}

.editor-topbar__credit {
  display: block;
  grid-column: 1 / -1;
  justify-self: end;
  margin-top: -0.35rem;
  color: rgba(48, 41, 34, 0.32);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  line-height: 1;
  white-space: nowrap;
}

.editor-export-field {
  display: grid;
  gap: 0.24rem;
  min-width: 10.5rem;
}

.editor-export-field--compact {
  min-width: 5.8rem;
}

.editor-export-field span {
  color: var(--editor-ink-soft);
  font-size: 0.8rem;
}

.editor-project-title {
  display: grid;
  gap: 0.28rem;
  min-width: 18rem;
}

.editor-project-title span {
  color: var(--editor-ink-soft);
  font-size: 0.82rem;
}

.editor-status-group,
.editor-stage-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.editor-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.36rem 0.62rem;
  border: 1px solid var(--editor-rule-soft);
  background: rgba(248, 250, 252, 0.82);
  font-size: 0.86rem;
}

.editor-badge--muted {
  color: var(--editor-ink-soft);
}

.editor-pagebar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.8rem 1.2rem;
  border-bottom: 1px solid var(--editor-rule-soft);
  background: rgba(238, 242, 245, 0.9);
  backdrop-filter: blur(16px) saturate(118%);
}

.editor-page-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.editor-page-tab-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  gap: 0.42rem;
}

.editor-page-tab {
  display: grid;
  gap: 0.1rem;
  min-width: 9rem;
  width: 100%;
  padding: 0.56rem 0.7rem;
  border: 1px solid var(--editor-rule-soft);
  border-radius: 1rem;
  background: rgba(247, 249, 251, 0.82);
  text-align: left;
}

.editor-page-tab-delete {
  align-self: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  min-width: 2rem;
  height: 2rem;
  padding: 0;
  border: 1px solid rgba(132, 108, 84, 0.16);
  border-radius: 0.78rem;
  background: rgba(255, 255, 255, 0.72);
  color: var(--editor-ink-soft);
  font-size: 1rem;
  line-height: 1;
  transition:
    border-color 180ms ease,
    color 180ms ease,
    background 180ms ease,
    transform 180ms ease;
}

.editor-page-tab-delete:hover {
  border-color: rgba(186, 96, 66, 0.28);
  background: rgba(255, 247, 243, 0.92);
  color: var(--editor-accent-strong);
  transform: translateY(-1px);
}

.editor-page-tab-delete:disabled {
  opacity: 0.42;
  cursor: not-allowed;
  transform: none;
}

.editor-page-tab.is-active {
  border-color: var(--editor-rule);
  background: rgba(255, 255, 255, 1);
}

.editor-page-tab__title {
  font-size: 0.92rem;
  font-weight: 600;
}

.editor-page-tab__meta {
  color: var(--editor-ink-soft);
  font-size: 0.78rem;
}

.editor-page-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.editor-workspace {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(300px, 360px) minmax(0, 1fr);
  gap: 1rem;
  padding: 1rem;
}

.editor-mobile-dock {
  display: none;
}

.editor-mobile-structure-toggle,
.editor-mobile-structure-scrim {
  display: none;
}

.editor-mobile-dock__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
}

.editor-mobile-dock__label {
  font-size: 0.92rem;
  font-weight: 600;
}

.editor-sidebar,
.editor-stage {
  min-width: 0;
}

.editor-panel {
  height: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.95rem;
  padding: 1rem;
  border: 1px solid var(--editor-rule);
  border-radius: 1.25rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(245, 248, 250, 0.98));
  box-shadow: var(--editor-shadow);
  backdrop-filter: blur(18px) saturate(125%);
}

.editor-section-title {
  padding-bottom: 0.55rem;
  border-bottom: 3px double var(--editor-rule);
  font-family: "Noto Serif SC", "Source Han Serif", "Noto Serif CJK SC", "Songti SC", serif;
  font-size: 1.02rem;
}

.editor-section {
  display: grid;
  gap: 0.72rem;
}

.editor-section h2 {
  margin: 0;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--editor-rule-soft);
  font-size: 0.98rem;
  font-family: "Noto Serif SC", "Source Han Serif", "Noto Serif CJK SC", "Songti SC", serif;
}

.editor-section-toggle,
.editor-collapsible-card__toggle {
  width: 100%;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
}

.editor-section-toggle {
  align-items: flex-start;
  padding-bottom: 0.52rem;
  border-bottom: 1px solid var(--editor-rule-soft);
  font-size: 0.98rem;
  font-family: "Noto Serif SC", "Source Han Serif", "Noto Serif CJK SC", "Songti SC", serif;
}

.editor-section-toggle__text {
  min-width: 0;
  display: grid;
  gap: 0.16rem;
}

.editor-section-toggle__label {
  font-weight: 600;
  color: var(--editor-ink);
}

.editor-section-toggle__label--strong {
  font-weight: 700;
}

.editor-section-toggle__meta {
  color: var(--editor-ink-soft);
  font-size: 0.74rem;
  font-family: "Noto Sans SC", "Source Han Sans", "Noto Sans CJK SC", "Microsoft YaHei", sans-serif;
  letter-spacing: 0.02em;
  line-height: 1.35;
}

.editor-collapsible-card__header {
  display: flex;
  align-items: center;
  gap: 0.72rem;
}

.editor-section-toggle:hover,
.editor-collapsible-card__toggle:hover {
  background: transparent;
}

.editor-section-toggle:hover .editor-section-toggle__label,
.editor-section-toggle:focus-visible .editor-section-toggle__label {
  color: var(--editor-accent);
}

.editor-collapsible-card__toggle {
  flex: 1 1 auto;
}

.editor-section-toggle__icon,
.editor-collapsible-card__icon {
  position: relative;
  flex: 0 0 auto;
  width: 0.85rem;
  height: 0.85rem;
  color: var(--editor-ink-soft);
  transition: transform 220ms ease;
}

.editor-section-toggle__icon::before,
.editor-collapsible-card__icon::before {
  content: "";
  position: absolute;
  inset: 0.16rem 0.18rem 0.18rem 0.16rem;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
}

.editor-section-toggle.is-open .editor-section-toggle__icon,
.editor-collapsible-card.is-open .editor-collapsible-card__icon,
.editor-collapsible-card__toggle.is-open .editor-collapsible-card__icon {
  transform: rotate(180deg);
}

.editor-collapsible-content {
  display: grid;
  grid-template-rows: 0fr;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transition: grid-template-rows 260ms cubic-bezier(0.22, 1, 0.36, 1), opacity 200ms ease;
}

.editor-collapsible-card.is-open .editor-collapsible-content,
.editor-collapsible-content.is-open {
  grid-template-rows: 1fr;
  opacity: 1;
  pointer-events: auto;
}

.editor-collapsible-content__inner {
  min-height: 0;
  overflow: hidden;
}

.editor-section--collapsible .editor-collapsible-content__inner {
  padding-top: 0.74rem;
}

.editor-section--collapsible .editor-style-section {
  padding-top: 0;
}

.editor-collapsible-card.is-inactive {
  opacity: 0.64;
}

.editor-card-check {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.08rem;
  height: 1.08rem;
  margin: 0;
  cursor: pointer;
}

.editor-card-check__input {
  width: 1rem;
  height: 1rem;
  margin: 0;
  accent-color: var(--editor-accent);
  cursor: pointer;
}

.editor-field {
  display: grid;
  gap: 0.28rem;
}

.editor-field.is-disabled {
  opacity: 0.58;
}

.editor-field span {
  color: var(--editor-ink-soft);
  font-size: 0.84rem;
}

.editor-field textarea {
  resize: vertical;
}

.editor-style-section {
  display: grid;
  gap: 0.72rem;
  padding-top: 0.3rem;
}

.editor-style-card {
  display: grid;
  gap: 0.62rem;
  padding: 0.76rem 0.8rem;
  border: 1px solid rgba(132, 108, 84, 0.14);
  border-radius: 1rem;
  background: rgba(255, 252, 248, 0.8);
}

.editor-style-card__heading {
  font-family: "Noto Serif SC", "Source Han Serif", "Noto Serif CJK SC", "Songti SC", serif;
  font-size: 0.94rem;
  font-weight: 600;
}

.editor-style-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

.editor-field--span-2 {
  grid-column: span 2;
}

.editor-style-card--field {
  gap: 0.78rem;
  padding: 0.9rem;
}

.editor-collapsible-card {
  gap: 0.78rem;
}

.editor-style-subsection {
  display: grid;
  gap: 0.55rem;
}

.editor-style-subsection__title {
  color: var(--editor-ink-soft);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.editor-style-divider {
  height: 1px;
  background: linear-gradient(90deg, rgba(76, 85, 96, 0), rgba(76, 85, 96, 0.18), rgba(76, 85, 96, 0));
}

.editor-crop-control {
  display: grid;
  gap: 0.46rem;
}

.editor-crop-control--soft {
  padding: 0.64rem 0.72rem;
  border: 1px solid rgba(132, 108, 84, 0.14);
  border-radius: 1rem;
  background: rgba(255, 252, 248, 0.72);
}

.editor-crop-control--soft.is-disabled {
  opacity: 0.56;
}

.editor-crop-control__label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  color: var(--editor-ink-soft);
  font-size: 0.82rem;
}

.editor-crop-control__inputs {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 5.4rem;
  gap: 0.55rem;
  align-items: center;
}

.editor-crop-control__range {
  width: 100%;
}

.editor-crop-control__number {
  width: 100%;
}

.editor-style-toolbar-stack {
  display: grid;
  gap: 0.58rem;
}

.editor-style-toolbar-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
}

.editor-style-toolbar-label {
  color: var(--editor-ink-soft);
  font-size: 0.82rem;
}

.editor-style-toolbar-group-stack {
  display: grid;
  gap: 0.36rem;
}

.editor-style-toolbar-group {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.36rem;
}

.editor-toolbar-button {
  min-width: 0;
  width: 2.35rem;
  height: 2.35rem;
  padding: 0;
  border-radius: 0.76rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.96);
  color: var(--editor-ink-soft);
}

.editor-toolbar-button:hover {
  background: rgba(243, 246, 248, 0.98);
}

.editor-toolbar-button.is-active {
  border-color: rgba(67, 76, 84, 0.32);
  background: rgba(67, 76, 84, 0.92);
  color: #f7f9fb;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.editor-toolbar-button svg {
  width: 1rem;
  height: 1rem;
  stroke: currentColor;
  stroke-width: 1.55;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.editor-toolbar-button__glyph {
  font-size: 1rem;
  line-height: 1;
}

.editor-toolbar-button__glyph--bold {
  font-weight: 700;
}

.editor-toolbar-button__glyph--italic {
  font-style: italic;
  font-family: Georgia, "Times New Roman", serif;
}

.editor-toolbar-button__glyph--underline {
  text-decoration: underline;
  text-underline-offset: 0.12em;
}

.editor-font-picker {
  position: relative;
  min-width: 0;
}

.editor-font-picker summary {
  list-style: none;
}

.editor-font-picker summary::-webkit-details-marker {
  display: none;
}

.editor-font-picker__trigger {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 0.16rem 0.72rem;
  align-items: center;
  padding: 0.62rem 0.74rem;
  border: 1px solid rgba(76, 85, 96, 0.22);
  border-radius: 0.92rem;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(14px) saturate(118%);
  cursor: pointer;
  transition: border-color 140ms ease, box-shadow 140ms ease, background-color 140ms ease;
}

.editor-font-picker__trigger:hover {
  border-color: rgba(76, 85, 96, 0.3);
  background: rgba(246, 248, 250, 0.98);
}

.editor-font-picker[open] .editor-font-picker__trigger {
  border-color: rgba(67, 76, 84, 0.34);
  box-shadow: 0 0 0 3px rgba(67, 76, 84, 0.08);
}

.editor-font-picker__trigger-meta {
  color: var(--editor-ink-faint);
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.editor-font-picker__trigger-label,
.editor-font-picker__trigger-sample,
.editor-font-picker__option-label,
.editor-font-picker__option-sample {
  min-width: 0;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.editor-font-picker__trigger-label {
  color: var(--editor-ink);
  font-size: 1rem;
  line-height: 1.2;
}

.editor-font-picker__trigger-sample {
  color: var(--editor-ink-soft);
  font-size: 0.84rem;
  line-height: 1.2;
}

.editor-font-picker__status {
  align-self: center;
  justify-self: end;
  padding: 0.18rem 0.46rem;
  border: 1px solid rgba(176, 127, 46, 0.24);
  border-radius: 999px;
  background: rgba(204, 164, 86, 0.12);
  color: #9a6b15;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.editor-font-picker__trigger-icon {
  position: relative;
  width: 0.95rem;
  height: 0.95rem;
  justify-self: end;
  align-self: center;
}

.editor-font-picker__trigger-icon::before,
.editor-font-picker__trigger-icon::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 0.46rem;
  height: 1.6px;
  background: currentColor;
  border-radius: 999px;
  transition: transform 140ms ease;
}

.editor-font-picker__trigger-icon::before {
  left: 0.05rem;
  transform: translateY(-50%) rotate(42deg);
}

.editor-font-picker__trigger-icon::after {
  right: 0.05rem;
  transform: translateY(-50%) rotate(-42deg);
}

.editor-font-picker[open] .editor-font-picker__trigger-icon::before {
  transform: translateY(-50%) rotate(-42deg);
}

.editor-font-picker[open] .editor-font-picker__trigger-icon::after {
  transform: translateY(-50%) rotate(42deg);
}

.editor-font-picker__menu {
  position: absolute;
  inset-inline: 0;
  top: calc(100% + 0.42rem);
  z-index: 40;
  display: grid;
  gap: 0.72rem;
  max-height: 19rem;
  overflow: auto;
  padding: 0.8rem;
  border: 1px solid rgba(76, 85, 96, 0.18);
  border-radius: 1rem;
  background: rgba(250, 252, 253, 0.98);
  box-shadow: 0 18px 40px rgba(31, 39, 46, 0.12);
  backdrop-filter: blur(20px) saturate(122%);
}

.editor-font-picker__group {
  display: grid;
  gap: 0.46rem;
}

.editor-font-picker__group-title {
  color: var(--editor-ink-faint);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.editor-font-picker__group-options {
  display: grid;
  gap: 0.36rem;
}

.editor-font-picker__option {
  width: 100%;
  min-width: 0;
  display: grid;
  gap: 0.12rem;
  justify-items: start;
  padding: 0.58rem 0.68rem;
  border: 1px solid rgba(132, 108, 84, 0.14);
  border-radius: 0.82rem;
  background: rgba(255, 252, 248, 0.92);
  color: var(--editor-ink);
  text-align: left;
  transition: border-color 140ms ease, background-color 140ms ease, transform 140ms ease;
}

.editor-font-picker__option:hover {
  border-color: rgba(132, 108, 84, 0.24);
  background: rgba(251, 245, 239, 0.98);
  transform: translateY(-1px);
}

.editor-font-picker__option.is-active {
  border-color: rgba(201, 121, 83, 0.28);
  background: rgba(255, 247, 241, 0.96);
  box-shadow: inset 0 0 0 1px rgba(201, 121, 83, 0.08);
}

.editor-font-picker__option.is-unavailable {
  background: rgba(248, 244, 234, 0.92);
}

.editor-font-picker__option-label {
  font-size: 0.96rem;
  line-height: 1.2;
}

.editor-font-picker__option-sample {
  color: var(--editor-ink-soft);
  font-size: 0.82rem;
  line-height: 1.2;
}

.editor-font-picker__option-note {
  color: #9a6b15;
  font-size: 0.74rem;
  line-height: 1.3;
}

.editor-text-style-color {
  display: grid;
  gap: 0;
}

.editor-inline-color.is-disabled {
  opacity: 0.56;
}

.editor-text-style-color__bar {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.52rem;
  padding: 0.42rem 0.52rem;
  border: 1px solid rgba(132, 108, 84, 0.2);
  border-radius: 1rem;
  background: rgba(255, 252, 248, 0.96);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.74);
  backdrop-filter: blur(12px) saturate(112%);
}

.editor-inline-color.is-disabled .editor-text-style-color__bar {
  background: rgba(242, 236, 229, 0.82);
}

.editor-text-style-color__swatch-button {
  position: relative;
  min-width: 0;
  padding: 0.18rem;
  border: 0;
  border-radius: 0.72rem;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.editor-text-style-color__swatch-button:hover {
  background: rgba(244, 236, 229, 0.92);
}

.editor-text-style-color__picker {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.editor-text-style-color__picker:disabled {
  cursor: not-allowed;
}

.editor-text-style-color__hex-input {
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 0;
  font-family: "Courier Prime", "Courier New", monospace;
  font-size: 0.98rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.editor-text-style-color__hex-input:focus {
  outline: none;
}

.editor-text-style-color__copy-button {
  min-width: 0;
  padding: 0.42rem 0.7rem;
  border-radius: 0.76rem;
  white-space: nowrap;
  background: rgba(255, 249, 244, 0.88);
}

.editor-text-style-color__copy-button:hover {
  background: rgba(251, 243, 236, 0.98);
}

.editor-text-style-color .editor-color-control__swatch {
  width: 2.85rem;
  height: 1.38rem;
  border-radius: 0.18rem;
}

.editor-switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.2rem 0;
}

.editor-switch-row.is-disabled {
  opacity: 0.56;
}

.editor-switch-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.editor-switch-input {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.editor-switch {
  position: relative;
  display: inline-flex;
  width: 2.85rem;
  height: 1.7rem;
  border: 1px solid rgba(132, 108, 84, 0.24);
  border-radius: 999px;
  background: rgba(223, 214, 203, 0.9);
  transition: background-color 120ms ease, border-color 120ms ease;
}

.editor-switch::after {
  content: "";
  position: absolute;
  top: 0.14rem;
  left: 0.16rem;
  width: 1.14rem;
  height: 1.14rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 1px 2px rgba(34, 40, 48, 0.18);
  transition: transform 120ms ease;
}

.editor-switch-input:checked + .editor-switch {
  border-color: rgba(169, 95, 61, 0.28);
  background: rgba(201, 121, 83, 0.92);
}

.editor-switch-input:checked + .editor-switch::after {
  transform: translateX(1.12rem);
}

.editor-segmented {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  width: fit-content;
  padding: 0.28rem;
  border: 1px solid rgba(132, 108, 84, 0.16);
  border-radius: 1rem;
  background: rgba(255, 252, 248, 0.92);
  backdrop-filter: blur(12px) saturate(112%);
}

.editor-segmented__button {
  min-width: 5.8rem;
  padding: 0.52rem 0.86rem;
  border: 0;
  border-radius: 0.78rem;
  background: transparent;
  color: var(--editor-ink-soft);
}

.editor-segmented__button:hover {
  background: rgba(243, 235, 227, 0.92);
}

.editor-segmented__button.is-active {
  background: linear-gradient(180deg, #d0885f 0%, #c36f48 100%);
  color: #fffaf7;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.editor-segmented__button:disabled {
  opacity: 0.46;
  cursor: not-allowed;
}

.editor-color-control {
  width: auto;
  justify-self: start;
  min-width: 8.4rem;
  display: inline-flex;
  align-items: center;
  gap: 0.72rem;
  padding: 0.38rem 0.72rem;
  border: 1px solid rgba(76, 85, 96, 0.28);
  border-radius: 0.6rem;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(14px) saturate(118%);
}

.editor-color-control--disabled {
  opacity: 0.56;
  background: rgba(237, 241, 244, 0.86);
}

.editor-color-control__swatch {
  width: 1.75rem;
  height: 1.1rem;
  border: 1px solid rgba(76, 85, 96, 0.2);
  background: #efe3c7;
  flex: 0 0 auto;
}

.editor-color-control__hex {
  font-family: "Courier Prime", "Courier New", monospace;
  font-size: 0.98rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.editor-color-panel {
  display: grid;
  gap: 0.72rem;
  padding: 0.72rem;
  border: 1px solid rgba(76, 85, 96, 0.16);
  border-radius: 1rem;
  background: rgba(249, 251, 252, 0.98);
  backdrop-filter: blur(14px) saturate(118%);
}

.editor-color-panel input[type="color"] {
  inline-size: min(100%, 5.2rem);
  block-size: 2.4rem;
  padding: 0;
  border: 1px solid rgba(76, 85, 96, 0.24);
  background: transparent;
  cursor: pointer;
}

.editor-color-hex-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.62rem;
}

.editor-meta-list {
  margin: 0;
  display: grid;
  gap: 0.45rem;
}

.editor-meta-list div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.28rem;
  border-bottom: 1px dotted var(--editor-rule-soft);
}

.editor-meta-list dt {
  color: var(--editor-ink-soft);
}

.editor-meta-list dd {
  margin: 0;
  text-align: right;
}

.editor-hint {
  margin: -0.1rem 0 0;
  color: var(--editor-ink-soft);
  font-size: 0.82rem;
  line-height: 1.4;
}

.editor-button-row,
.editor-sidebar-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

.editor-sidebar-actions {
  margin-top: auto;
}

.editor-primary-btn {
  background: rgba(61, 69, 77, 0.94);
  color: #f5f7f9;
}

.editor-primary-btn:hover {
  background: rgba(49, 57, 64, 0.98);
}

.editor-stack {
  display: grid;
  gap: 0.72rem;
}

.editor-region-list {
  display: grid;
  gap: 0.5rem;
}

.editor-region-item {
  display: grid;
  gap: 0.16rem;
  padding: 0.6rem 0.7rem;
  border: 1px solid var(--editor-rule-soft);
  border-radius: 0.95rem;
  background: rgba(250, 251, 252, 0.84);
  text-align: left;
}

.editor-region-item.is-active {
  border-color: var(--editor-accent);
  background: var(--editor-accent-soft);
}

.editor-region-item__title {
  font-weight: 600;
}

.editor-region-item__meta {
  color: var(--editor-ink-soft);
  font-size: 0.78rem;
}

.editor-empty-state {
  padding: 0.9rem 1rem;
  border: 1px dashed rgba(132, 108, 84, 0.28);
  border-radius: 1rem;
  color: var(--editor-ink-soft);
  background: rgba(255, 251, 247, 0.72);
}

.editor-stage {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.editor-stage-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--editor-rule);
  border-radius: 1.2rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(243, 246, 248, 0.98));
  box-shadow: var(--editor-shadow);
  backdrop-filter: blur(18px) saturate(122%);
}

.editor-paper-wrap {
  flex: 1;
  min-height: 0;
  border: 1px solid var(--editor-rule);
  border-radius: 1.35rem;
  padding: 1rem;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.42), rgba(0, 0, 0, 0)),
    linear-gradient(180deg, rgba(239, 243, 246, 0.98), rgba(223, 229, 234, 0.98));
  box-shadow: var(--editor-shadow);
  backdrop-filter: blur(18px) saturate(122%);
}

.editor-paper-viewport {
  width: 100%;
  display: flex;
  justify-content: center;
  position: relative;
}

.editor-paper {
  width: min(100%, 720px);
  margin: 0 auto;
  padding: min(1.05rem, 2.1cqw) min(1.12rem, 2.24cqw) min(0.98rem, 1.96cqw);
  aspect-ratio: 210 / 297;
  position: relative;
  isolation: isolate;
  container-type: inline-size;
  display: grid;
  grid-template-rows: auto 1fr auto;
  --paper-chrome-color: var(--editor-ink-soft);
  --paper-chrome-font-family: "Noto Sans SC", "Source Han Sans", "Noto Sans CJK SC", "Microsoft YaHei", sans-serif;
  --paper-structure-line-color: #2f2418;
  --paper-structure-line-width: 1px;
  --paper-structure-line-style: solid;
  --masthead-decoration-color: #2f2418;
  border: 0;
  background: transparent;
  box-shadow: 0 16px 42px rgba(31, 23, 15, 0.16);
  background-size: cover;
  background-position: center;
}

body.is-exporting .editor-paper {
  width: 720px !important;
  position: relative !important;
  top: auto !important;
  left: auto !important;
  max-width: none !important;
  transform: none !important;
  box-shadow: none !important;
}

body.is-export-transparent.is-exporting .editor-paper,
body.is-export-transparent.is-export-preview .editor-paper {
  background-image: none !important;
  background-color: transparent !important;
  box-shadow: none !important;
}

body.is-export-transparent.is-exporting,
body.is-export-transparent.is-export-preview,
body.is-export-transparent.is-exporting .editor-shell,
body.is-export-transparent.is-export-preview .editor-shell,
body.is-export-transparent.is-exporting .editor-workspace,
body.is-export-transparent.is-export-preview .editor-workspace,
body.is-export-transparent.is-exporting .editor-stage,
body.is-export-transparent.is-export-preview .editor-stage,
body.is-export-transparent.is-exporting .editor-paper-wrap,
body.is-export-transparent.is-export-preview .editor-paper-wrap,
body.is-export-transparent.is-exporting .editor-paper-viewport,
body.is-export-transparent.is-export-preview .editor-paper-viewport {
  background: transparent !important;
}

body.is-export-transparent.is-exporting .editor-paper-base-tint,
body.is-export-transparent.is-export-preview .editor-paper-base-tint {
  display: none !important;
}

body.is-exporting .editor-topbar,
body.is-exporting .editor-nav,
body.is-exporting .editor-sidebar,
body.is-exporting .editor-mobile-dock,
body.is-exporting .editor-stage-header {
  display: none !important;
}

body.is-exporting .editor-shell {
  min-height: auto !important;
  gap: 0 !important;
  padding: 0 !important;
}

body.is-exporting .editor-workspace {
  display: block !important;
  padding: 0 !important;
}

body.is-exporting .editor-stage {
  display: block !important;
  width: fit-content !important;
  margin: 0 auto !important;
}

body.is-exporting .editor-paper-wrap,
body.is-exporting .editor-paper-viewport {
  overflow: visible !important;
}

body.is-exporting .editor-paper-wrap {
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.is-exporting .editor-paper-viewport {
  display: block !important;
  min-width: 720px !important;
}

body.editor-export-renderer:not(.editor-print-renderer) .editor-paper-viewport {
  display: block;
  width: 720px;
  height: 1018px;
  min-width: 720px;
  overflow: hidden;
}

body.editor-export-renderer:not(.editor-print-renderer) .editor-paper {
  width: 720px !important;
  height: 1018px !important;
  min-width: 720px !important;
  max-width: none !important;
  margin: 0 !important;
  aspect-ratio: auto !important;
  transform: none !important;
  box-shadow: none !important;
}

.editor-export-snapshot {
  position: absolute;
  z-index: 8;
  top: 0;
  left: 50%;
  width: min(100%, 720px);
  aspect-ratio: 210 / 297;
  margin: 0 auto;
  transform: translateX(-50%);
  display: grid;
  place-items: center;
  background: rgba(245, 239, 231, 0.84);
  color: var(--editor-ink-soft);
  font-size: 0.92rem;
  text-align: center;
  pointer-events: none;
}

.editor-export-snapshot.hidden {
  display: none;
}

.editor-export-snapshot__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: fill;
}

.editor-export-snapshot__image:not([src]),
.editor-export-snapshot__image[src=""] {
  display: none;
}

.editor-export-snapshot__status {
  position: relative;
  z-index: 1;
  padding: 0.56rem 0.72rem;
  border: 1px solid rgba(132, 108, 84, 0.18);
  border-radius: 0.65rem;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 30px rgba(80, 52, 32, 0.12);
}

.editor-export-snapshot.has-image {
  background: transparent;
}

.editor-export-snapshot.has-image .editor-export-snapshot__status {
  display: none;
}

.editor-paper-base-tint {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(180deg, var(--editor-paper-preview) 0%, #e8dcc2 100%);
  opacity: 0.46;
}

.editor-paper__header,
.editor-paper__footer {
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
}

.editor-paper__header {
  gap: min(0.16rem, 0.32cqw);
}

.editor-paper__footer {
  gap: min(0.45rem, 0.9cqw);
}

.editor-paper__title-line {
  border-top: 3px double var(--paper-chrome-color);
}

.editor-paper__meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: min(0.8rem, 1.6cqw);
  font-family: var(--paper-chrome-font-family);
  color: var(--paper-chrome-color);
}

.editor-content-area {
  position: relative;
  margin: min(0.72rem, 1.44cqw) 0;
  z-index: 1;
  overflow: hidden;
  background: transparent;
}

.editor-content-area.is-grid-editable {
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}

.editor-grid-cells {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(var(--grid-cols, 4), 1fr);
  grid-template-rows: repeat(var(--grid-rows, 6), 1fr);
  opacity: 1;
  transition: opacity 140ms ease;
}

body[data-view="editor"] .editor-grid-cells {
  opacity: 0;
  pointer-events: none;
}

.editor-grid-cell {
  position: relative;
  border-right: 1px solid var(--editor-grid);
  border-bottom: 1px solid var(--editor-grid);
}

.editor-grid-cell::before {
  content: attr(data-label);
  position: absolute;
  top: 0.3rem;
  left: 0.34rem;
  font-size: 0.66rem;
  color: rgba(72, 54, 38, 0.58);
}

.editor-grid-cell.is-locked {
  background: linear-gradient(135deg, rgba(36, 29, 23, 0.08), rgba(36, 29, 23, 0.02));
}

.editor-grid-cell.is-filled {
  background: linear-gradient(180deg, rgba(67, 46, 27, 0.06), rgba(67, 46, 27, 0));
}

.editor-regions-layer,
.editor-outer-frame-layer,
.editor-shared-borders-layer,
.editor-selection-overlay,
.editor-masthead-overlay {
  position: absolute;
  inset: 0;
}

.editor-outer-frame-layer,
.editor-shared-borders-layer,
.editor-regions-layer {
  pointer-events: none;
}

.editor-outer-frame-layer {
  z-index: 5;
  border: var(--editor-structure-line-width, 1px) var(--editor-structure-line-style, solid) var(--editor-structure-line-color, #2f2418);
}

.editor-region-block {
  position: absolute;
  display: flex;
  align-items: stretch;
  justify-content: stretch;
  padding: 0.2rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  pointer-events: auto;
  cursor: pointer;
  overflow: hidden;
}

.editor-region-block.is-selected {
  background: var(--editor-region-selected);
  box-shadow: inset 0 0 0 2px var(--editor-accent);
}

.editor-region-block--setup {
  align-items: stretch;
  justify-content: stretch;
  box-shadow: inset 0 0 0 1px rgba(49, 40, 29, 0.58);
}

.editor-region-block--setup.is-selected {
  box-shadow: inset 0 0 0 2px var(--editor-accent);
}

.editor-shared-border {
  position: absolute;
  pointer-events: none;
  z-index: 4;
}

.editor-shared-border--vertical {
  width: 0;
  border-left: var(--editor-structure-line-width, 1px) var(--editor-structure-line-style, solid) var(--editor-structure-line-color, #2f2418);
  transform: translateX(calc(var(--editor-structure-line-width, 1px) / -2));
}

.editor-shared-border--horizontal {
  height: 0;
  border-top: var(--editor-structure-line-width, 1px) var(--editor-structure-line-style, solid) var(--editor-structure-line-color, #2f2418);
  transform: translateY(calc(var(--editor-structure-line-width, 1px) / -2));
}

.editor-region-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.2rem;
  min-height: 1.75rem;
  padding: 0.18rem 0.42rem;
  border: 1px solid rgba(49, 40, 29, 0.84);
  border-radius: 0;
  background: rgba(255, 248, 232, 0.82);
  font-size: 0.78rem;
}

.editor-region-tag--overlay {
  position: absolute;
  top: 0.22rem;
  right: 0.22rem;
  z-index: 2;
  min-width: 1.9rem;
  min-height: 1.45rem;
  padding: 0.12rem 0.34rem;
  font-size: 0.72rem;
  background: rgba(255, 249, 238, 0.94);
}

.editor-region-preview {
  position: relative;
  width: 100%;
  height: 100%;
  display: grid;
  grid-auto-rows: min-content;
  gap: 0.28rem;
  align-content: start;
  overflow: hidden;
  padding: 0.32rem 0.38rem;
}

.editor-region-preview--setup {
  padding-top: 0.52rem;
}

.editor-region-preview--image-card {
  display: flex;
  align-items: stretch;
  justify-content: stretch;
}

.editor-region-preview--image-horizontal {
  flex-direction: column;
}

.editor-region-preview--image-vertical {
  flex-direction: row;
}

.editor-region-preview__image-copy {
  min-width: 0;
  min-height: 0;
  display: grid;
  gap: 0.28rem;
  align-content: start;
}

.editor-region-preview__image-copy--vertical-rl {
  writing-mode: vertical-rl;
  text-orientation: mixed;
}

.editor-region-preview__image-copy--horizontal-rtl {
  direction: rtl;
  text-align: right;
}

.editor-region-preview--horizontal-rtl .editor-region-preview__title,
.editor-region-preview--horizontal-rtl .editor-region-preview__subtitle,
.editor-region-preview--horizontal-rtl .editor-region-preview__caption,
.editor-region-preview--horizontal-rtl .editor-region-preview__meta-line,
.editor-region-preview--horizontal-rtl .editor-region-preview__paragraph,
.editor-region-preview--horizontal-rtl .editor-region-preview__brief li,
.editor-region-preview__image-copy--horizontal-rtl .editor-region-preview__title,
.editor-region-preview__image-copy--horizontal-rtl .editor-region-preview__subtitle,
.editor-region-preview__image-copy--horizontal-rtl .editor-region-preview__caption,
.editor-region-preview__image-copy--horizontal-rtl .editor-region-preview__meta-line,
.editor-region-preview__image-copy--horizontal-rtl .editor-region-preview__paragraph,
.editor-region-preview__image-copy--horizontal-rtl .editor-region-preview__brief li {
  direction: inherit;
  unicode-bidi: bidi-override;
}

.editor-region-preview__image-copy--horizontal-ltr {
  direction: ltr;
  text-align: left;
}

.editor-region-preview--vertical-rl {
  writing-mode: vertical-rl;
  text-orientation: mixed;
}

.editor-region-preview--horizontal-rtl {
  direction: rtl;
  text-align: right;
}

.editor-region-preview__title {
  color: var(--editor-ink);
  font-family: "ZhaohuaMinA", "Noto Serif SC", "Source Han Serif", "Noto Serif CJK SC", "Songti SC", serif;
  font-size: 1.18rem;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: 0.03em;
  white-space: pre-wrap;
}

.editor-region-preview__subtitle {
  color: var(--editor-ink);
  font-family: "ZhaohuaTypeWriter Light", "Courier New", monospace;
  font-size: 0.72rem;
  line-height: 1.45;
  letter-spacing: 0.06em;
  white-space: pre-wrap;
}

.editor-region-preview__body,
.editor-region-preview__caption,
.editor-region-preview__brief,
.editor-region-preview__meta-line {
  color: var(--editor-ink);
  font-family: "ZhaohuaTypeWriter Light", "Courier New", monospace;
  font-size: 0.86rem;
  line-height: 1.6;
  letter-spacing: 0.02em;
  white-space: pre-wrap;
}

.editor-region-preview__paragraph {
  margin: 0;
  white-space: pre-wrap;
}

.editor-region-preview__paragraph--blank {
  min-height: 1em;
}

.editor-region-preview__paragraph--dropcap {
  text-indent: 0;
}

.editor-region-preview__body--dropcap .editor-region-preview__dropcap {
  float: left;
  margin-right: 0.16em;
  line-height: 0.94;
  font-size: 2.9em;
  font-weight: 700;
}

.editor-region-preview--horizontal-rtl .editor-region-preview__body--dropcap .editor-region-preview__dropcap {
  float: right;
  margin-right: 0;
  margin-left: 0.16em;
}

.editor-region-preview__image {
  position: relative;
  width: 100%;
  min-width: 0;
  min-height: 4.2rem;
  overflow: hidden;
  border: 1px solid rgba(49, 40, 29, 0.4);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.24), rgba(0, 0, 0, 0)),
    rgba(80, 63, 46, 0.12);
  display: block;
  color: var(--editor-ink);
  font-family: "ZhaohuaTypeWriter Light", "Courier New", monospace;
  font-size: 0.8rem;
  writing-mode: horizontal-tb;
  direction: ltr;
  cursor: grab;
  touch-action: none;
}

.editor-region-preview--image-card .editor-region-preview__image {
  flex: 1 1 auto;
}

.editor-region-preview--image-vertical .editor-region-preview__image {
  min-height: 0;
  height: 100%;
}

.editor-region-preview--image-vertical .editor-region-preview__image-copy {
  flex: 0 0 auto;
  max-width: 38%;
}

.editor-region-preview__image-placeholder {
  width: 100%;
  min-height: inherit;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.4rem;
  text-align: center;
}

.editor-region-preview__image--filled {
  background: rgba(80, 63, 46, 0.08);
}

.editor-region-preview__image.is-dragging,
.editor-region-preview__image--filled:active {
  cursor: grabbing;
}

.editor-region-preview__image-asset {
  display: block;
  width: 100%;
  height: 100%;
  user-select: none;
  -webkit-user-drag: none;
}

.editor-region-preview__image-positioner {
  position: absolute;
  left: 50%;
  top: 50%;
  transform-origin: center;
  will-change: transform;
}

.editor-region-preview__brief {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.16rem;
}

.editor-region-preview__brief li {
  padding-block-start: 0.16rem;
  border-block-start: 1px solid rgba(49, 40, 29, 0.24);
  white-space: pre-wrap;
}

.editor-region-preview__title,
.editor-region-preview__subtitle,
.editor-region-preview__body,
.editor-region-preview__caption,
.editor-region-preview__brief,
.editor-region-preview__meta-line,
.editor-region-preview__paragraph,
.editor-region-preview__brief li {
  word-break: normal;
  overflow-wrap: normal;
  line-break: strict;
  hanging-punctuation: allow-end;
}

.editor-region-preview__brief li:first-child {
  padding-block-start: 0;
  border-block-start: 0;
}

.editor-region-preview__meta-group {
  margin-top: auto;
  display: grid;
  gap: 0.14rem;
  padding-top: 0.18rem;
  border-top: 1px solid rgba(49, 40, 29, 0.28);
}

.editor-region-preview__meta-line {
  font-size: 0.74rem;
}

.editor-region-preview--tiny {
  gap: 0.14rem;
  padding: 0.2rem 0.24rem;
}

.editor-region-preview--tiny.editor-region-preview--setup {
  padding-top: 0.44rem;
}

.editor-region-preview--tiny .editor-region-preview__title {
  font-size: 0.92rem;
  line-height: 1.08;
}

.editor-region-preview--tiny .editor-region-preview__subtitle,
.editor-region-preview--tiny .editor-region-preview__body,
.editor-region-preview--tiny .editor-region-preview__caption,
.editor-region-preview--tiny .editor-region-preview__brief,
.editor-region-preview--tiny .editor-region-preview__meta-line {
  font-size: 0.66rem;
  line-height: 1.35;
}

.editor-region-preview--tiny .editor-region-preview__image {
  min-height: 2.4rem;
  font-size: 0.68rem;
}

.editor-region-preview--compact {
  gap: 0.2rem;
  padding: 0.24rem 0.28rem;
}

.editor-region-preview--compact.editor-region-preview--setup {
  padding-top: 0.48rem;
}

.editor-region-preview--compact .editor-region-preview__title {
  font-size: 1.04rem;
}

.editor-region-preview--compact .editor-region-preview__subtitle,
.editor-region-preview--compact .editor-region-preview__body,
.editor-region-preview--compact .editor-region-preview__caption,
.editor-region-preview--compact .editor-region-preview__brief,
.editor-region-preview--compact .editor-region-preview__meta-line {
  font-size: 0.74rem;
  line-height: 1.45;
}

.editor-region-preview--compact .editor-region-preview__image {
  min-height: 3rem;
}

.editor-region-preview--regular .editor-region-preview__title {
  font-size: 1.34rem;
}

.editor-region-preview--regular .editor-region-preview__subtitle {
  font-size: 0.82rem;
}

.editor-region-preview--regular .editor-region-preview__body,
.editor-region-preview--regular .editor-region-preview__caption,
.editor-region-preview--regular .editor-region-preview__brief {
  font-size: 0.92rem;
}

.editor-region-preview--regular .editor-region-preview__meta-line {
  font-size: 0.78rem;
}

.editor-region-preview--regular .editor-region-preview__image {
  min-height: 4.8rem;
}

.editor-region-preview--spacious {
  gap: 0.34rem;
  padding: 0.36rem 0.44rem;
}

.editor-region-preview--spacious.editor-region-preview--setup {
  padding-top: 0.58rem;
}

.editor-region-preview--spacious .editor-region-preview__title {
  font-size: 1.56rem;
}

.editor-region-preview--spacious .editor-region-preview__subtitle {
  font-size: 0.92rem;
}

.editor-region-preview--spacious .editor-region-preview__body,
.editor-region-preview--spacious .editor-region-preview__caption,
.editor-region-preview--spacious .editor-region-preview__brief {
  font-size: 0.98rem;
  line-height: 1.68;
}

.editor-region-preview--spacious .editor-region-preview__meta-line {
  font-size: 0.82rem;
}

.editor-region-preview--spacious .editor-region-preview__image {
  min-height: 5.6rem;
}

.editor-region-preview--vertical-rl .editor-region-preview__body,
.editor-region-preview--vertical-rl .editor-region-preview__caption,
.editor-region-preview--vertical-rl .editor-region-preview__brief {
  line-height: 1.8;
}

.editor-region-preview--vertical-rl .editor-region-preview__body--dropcap .editor-region-preview__dropcap {
  float: none;
  display: inline-block;
  margin-right: 0;
  margin-left: 0;
  margin-bottom: 0.18em;
  font-size: 2.2em;
  line-height: 1;
}

.editor-masthead-overlay {
  display: flex;
  padding: 0.2rem;
  border: 2px solid var(--masthead-decoration-color);
  background: transparent;
  pointer-events: none;
  overflow: hidden;
}

.editor-masthead-overlay::after {
  content: "Masthead";
  position: absolute;
  right: 0.42rem;
  top: 0.42rem;
  padding: 0.18rem 0.45rem;
  background: rgba(255, 247, 229, 0.9);
  border: 1px solid var(--editor-rule);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.editor-masthead-overlay[data-preview-layout="ornamental-centerpiece"] {
  padding: 0;
  border: 0;
}

.editor-masthead-overlay[data-preview-layout="ornamental-two-row-frame"] {
  padding: 0;
  border: 0;
}

body.is-exporting .editor-masthead-overlay::after,
body.is-export-preview .editor-masthead-overlay::after {
  display: none !important;
}

.masthead-preview {
  width: 100%;
  height: 100%;
  border: 1px solid var(--masthead-decoration-color);
  background: transparent;
  font-variant-east-asian: traditional;
}

.editor-masthead-overlay[data-preview-layout="ornamental-centerpiece"] .masthead-preview {
  border: 0;
}

.editor-masthead-overlay[data-preview-layout="ornamental-two-row-frame"] .masthead-preview {
  border: 0;
}

.masthead-preview__inner {
  width: 100%;
  height: 100%;
}

.masthead-preview--vertical .masthead-preview__inner,
.masthead-preview--horizontal .masthead-preview__inner {
  display: flex;
  flex-direction: column;
}

.masthead-preview--split-two-column .masthead-preview__inner,
.masthead-preview--split-three-column .masthead-preview__inner {
  display: flex;
  flex-direction: row;
}

.masthead-preview--newsplate .masthead-preview__inner {
  display: flex;
  flex-direction: column;
}

.masthead-preview--ornamental-centerpiece .masthead-preview__inner {
  display: flex;
  flex-direction: row;
}

.masthead-preview--ornamental-two-row-frame .masthead-preview__inner {
  display: flex;
  flex-direction: column;
}

.masthead-zone {
  min-width: 0;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.masthead-zone + .masthead-zone {
  border-top: 1px solid var(--masthead-decoration-color);
}

.masthead-preview--split-two-column .masthead-zone + .masthead-zone,
.masthead-preview--split-three-column .masthead-zone + .masthead-zone {
  border-top: 0;
  border-left: 1px solid var(--masthead-decoration-color);
}

.masthead-preview--ornamental-centerpiece .masthead-zone + .masthead-zone {
  border-top: 0;
  border-left: 0;
}

.masthead-preview--ornamental-two-row-frame .masthead-zone + .masthead-zone {
  border-top: 0;
  border-left: 0;
}

.masthead-zone--vertical-main {
  padding: 0.9rem 0.2rem 0.55rem;
}

.masthead-zone--fixed-image-main {
  padding: 0.55rem 0.14rem 0.42rem;
}

.masthead-title-vertical {
  writing-mode: vertical-rl;
  text-orientation: upright;
  font-size: calc(min(3.5rem, 4.8cqw) * var(--masthead-font-scale, 1));
  line-height: 1.05;
  letter-spacing: 0.06em;
  font-family: var(--masthead-title-font);
  font-weight: 400;
  text-align: center;
  text-shadow: 0 0.01em 0 rgba(49, 40, 29, 0.2);
}

.masthead-title-vertical--paperName {
  font-size: calc(min(5.2rem, 7.4cqw) * var(--masthead-font-scale, 1));
}

.masthead-fixed-image {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.masthead-fixed-image__asset {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  filter: saturate(0.9) contrast(1.02);
}

.masthead-meta-line,
.masthead-meta-row {
  width: 100%;
  padding: 0.14rem 0.24rem;
  font-size: calc(min(1.22rem, 1.76cqw) * var(--masthead-font-scale, 1));
  line-height: 1.15;
  text-align: center;
  white-space: nowrap;
  font-family: var(--masthead-meta-font);
}

.masthead-meta-line--latin {
  font-family: var(--masthead-latin-font);
  font-size: calc(min(1.08rem, 1.56cqw) * var(--masthead-font-scale, 1));
  letter-spacing: 0.08em;
  font-variant: normal;
  text-transform: none;
}

.masthead-meta-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.2rem;
  flex-wrap: wrap;
}

.masthead-meta-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.12rem;
  border-right: 1px solid var(--masthead-decoration-color);
  font-family: var(--masthead-meta-font);
  font-size: calc(1em * var(--masthead-font-scale, 1));
}

.masthead-meta-chip:last-child {
  border-right: 0;
}

.masthead-meta-chip--latin {
  font-family: var(--masthead-latin-font);
  font-variant: normal;
  letter-spacing: 0.08em;
  text-transform: none;
}

.masthead-zone--horizontal-title,
.masthead-zone--title-panel-latin-top,
.masthead-zone--title-panel-latin-bottom,
.masthead-zone--meta-column,
.masthead-zone--newsplate-header,
.masthead-zone--ornamental-title-frame,
.masthead-zone--double-rule,
.masthead-zone--news-meta-bar {
  padding-inline: 0.18rem;
}

.masthead-zone--horizontal-title {
  padding-top: 0.16rem;
  padding-bottom: 0.08rem;
}

.masthead-zone--title-panel-latin-top,
.masthead-zone--title-panel-latin-bottom {
  padding-top: 0.1rem;
  padding-bottom: 0.08rem;
}

.masthead-zone--meta-column {
  padding-top: 0.1rem;
  padding-bottom: 0.1rem;
}

.masthead-zone--newsplate-header {
  padding-top: 0.08rem;
  padding-bottom: 0.02rem;
}

.masthead-zone--ornamental-title-frame {
  padding-top: 0.04rem;
  padding-bottom: 0.02rem;
  padding-inline: 0.08rem;
}

.masthead-zone--double-rule {
  padding-top: 0.02rem;
  padding-bottom: 0;
}

.masthead-zone--news-meta-bar {
  padding-top: 0.04rem;
  padding-bottom: 0.08rem;
}

.masthead-preview--horizontal-thin .masthead-zone--horizontal-title,
.masthead-preview--horizontal-tall .masthead-zone--horizontal-title {
  padding-top: 0.22rem;
  padding-bottom: 0.12rem;
}

.masthead-preview--newsplate .masthead-zone--double-rule {
  border-top: 0;
}

.masthead-preview--newsplate .masthead-zone {
  align-items: stretch;
}

.masthead-preview--history-banner .masthead-zone + .masthead-zone {
  border-top: 0;
}

.masthead-preview--history-banner .masthead-zone--archive-kicker {
  padding: 0.09rem 0.24rem 0.06rem;
  border-bottom: 1px solid var(--masthead-decoration-color);
}

.masthead-preview--history-banner .masthead-zone--horizontal-title {
  padding: 0.08rem 0.2rem 0.02rem;
}

.masthead-preview--history-banner .masthead-zone--archive-subline {
  padding: 0.02rem 0.2rem 0.08rem;
}

.masthead-preview--history-banner .masthead-zone--news-meta-bar {
  padding: 0.06rem 0.18rem 0.1rem;
}

.masthead-preview--history-banner .masthead-zone--archive-kicker .masthead-meta-line {
  padding: 0;
  font-size: calc(min(0.8rem, 1.18cqw) * var(--masthead-font-scale, 1));
  line-height: 1;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.masthead-preview--history-banner .masthead-zone--archive-kicker .masthead-meta-line--latin {
  font-family: var(--masthead-latin-font);
}

.masthead-preview--history-banner .masthead-zone--horizontal-title .masthead-title-horizontal {
  padding: 0;
}

.masthead-preview--history-banner .masthead-title-horizontal--paperName {
  font-size: calc(min(4.5rem, 6.3cqw) * var(--masthead-font-scale, 1));
  line-height: 0.9;
  letter-spacing: 0.02em;
}

.masthead-preview--history-banner .masthead-zone--archive-subline .masthead-meta-line {
  padding: 0;
  font-size: calc(min(0.8rem, 1.18cqw) * var(--masthead-font-scale, 1));
  line-height: 1.05;
  letter-spacing: 0.18em;
}

.masthead-preview--history-banner .masthead-zone--archive-subline .masthead-meta-line--publisher {
  font-family: var(--masthead-meta-font);
  font-weight: 700;
}

.masthead-preview--broadsheet-banner .masthead-zone + .masthead-zone {
  border-top: 0;
}

.masthead-preview--broadsheet-banner .masthead-zone--double-rule {
  padding: 0.08rem 0.22rem 0.04rem;
}

.masthead-preview--broadsheet-banner .masthead-double-rule {
  gap: 0.06rem;
}

.masthead-preview--broadsheet-banner .masthead-double-rule span {
  border-top-color: var(--masthead-decoration-color);
}

.masthead-preview--broadsheet-banner .masthead-zone--horizontal-title {
  padding: 0.02rem 0.2rem 0.04rem;
}

.masthead-preview--broadsheet-banner .masthead-title-horizontal--paperName {
  font-size: calc(min(5.6rem, 7.6cqw) * var(--masthead-font-scale, 1));
  line-height: 0.88;
  letter-spacing: 0.03em;
}

.masthead-preview--broadsheet-banner .masthead-zone--news-meta-bar {
  padding: 0.04rem 0.16rem 0.08rem;
}

.masthead-preview--broadsheet-banner .masthead-newsplate__bar {
  background: transparent;
  color: rgba(52, 40, 27, 0.96);
  border: 0;
  border-top: 2px solid var(--masthead-decoration-color);
  border-bottom: 2px solid var(--masthead-decoration-color);
  padding: 0.12rem 0.02rem 0.08rem;
  gap: 0.16rem;
}

.masthead-preview--broadsheet-banner .masthead-newsplate__bar-cell {
  overflow: visible;
  text-overflow: clip;
}

.masthead-preview--broadsheet-banner .masthead-newsplate__bar-cell--issueNumber {
  font-family: var(--masthead-meta-font);
  font-size: calc(min(0.9rem, 1.26cqw) * var(--masthead-font-scale, 1));
  font-weight: 700;
  letter-spacing: 0.05em;
}

.masthead-preview--broadsheet-banner .masthead-newsplate__bar-cell--latinName {
  position: relative;
  font-family: var(--masthead-latin-font);
  font-size: calc(min(1.12rem, 1.6cqw) * var(--masthead-font-scale, 1));
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: none;
}

.masthead-preview--broadsheet-banner .masthead-newsplate__bar-cell--latinName::before,
.masthead-preview--broadsheet-banner .masthead-newsplate__bar-cell--latinName::after {
  content: "";
  display: inline-block;
  width: 0.18rem;
  height: 0.18rem;
  margin: 0 0.18rem;
  border: 1px solid var(--masthead-decoration-color);
  transform: rotate(45deg);
  vertical-align: middle;
}

.masthead-preview--broadsheet-banner .masthead-newsplate__bar-cell--dateText {
  font-family: var(--masthead-meta-font);
  font-size: calc(min(0.9rem, 1.24cqw) * var(--masthead-font-scale, 1));
  font-weight: 700;
  letter-spacing: 0.05em;
}

.masthead-preview--label-banner .masthead-zone + .masthead-zone {
  border-top: 0;
}

.masthead-preview--label-banner .masthead-zone--news-meta-bar {
  padding: 0.05rem 0.16rem 0.08rem;
}

.masthead-preview--label-banner .masthead-zone--label-banner-header {
  padding: 0.05rem 0.18rem 0.16rem;
}

.masthead-preview--ornamental-centerpiece .masthead-zone {
  align-items: stretch;
}

.masthead-preview--ornamental-two-row-frame .masthead-zone {
  align-items: stretch;
}

.masthead-preview--ornamental-centerpiece .masthead-zone--meta-column {
  padding-top: 0.06rem;
  padding-bottom: 0.06rem;
}

.masthead-preview--ornamental-centerpiece .masthead-meta-column {
  justify-content: center;
}

.masthead-preview--ornamental-centerpiece .masthead-meta-column__group {
  gap: 0.14rem;
}

.masthead-preview--ornamental-centerpiece .masthead-meta-line {
  padding: 0.06rem 0.12rem;
  font-size: calc(min(0.9rem, 1.28cqw) * var(--masthead-font-scale, 1));
  line-height: 1.16;
  white-space: normal;
}

.masthead-ornamental-frame {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  --ornamental-copy-inset: 24% 25% 27%;
  --ornamental-title-shift: 0.02rem;
  --ornamental-latin-shift: 1.38rem;
}

.masthead-ornamental-frame__asset {
  position: absolute;
  inset: 0.02rem 0;
  width: 100%;
  height: calc(100% - 0.04rem);
  object-fit: contain;
  object-position: center;
  display: block;
  filter: saturate(0.92) contrast(1.04);
  pointer-events: none;
}

.masthead-ornamental-frame__copy {
  position: absolute;
  z-index: 1;
  inset: var(--ornamental-copy-inset);
  display: grid;
  place-items: center;
  padding: 0.02rem 0.18rem 0;
  text-align: center;
  min-width: 0;
}

.masthead-ornamental-frame__copy .masthead-title-horizontal,
.masthead-ornamental-frame__copy .masthead-meta-line {
  grid-area: 1 / 1;
  width: 100%;
  padding: 0;
  text-align: center;
}

.masthead-ornamental-frame__copy .masthead-title-horizontal--paperName {
  align-self: center;
  font-size: calc(min(3rem, 4.18cqw) * var(--masthead-font-scale, 1));
  line-height: 0.95;
  letter-spacing: 0.05em;
  white-space: nowrap;
  text-shadow: none;
  transform: translateY(calc(var(--ornamental-title-shift) * var(--masthead-font-scale, 1)));
}

.masthead-ornamental-frame__copy .masthead-meta-line--latin {
  align-self: center;
  font-size: calc(min(1rem, 1.42cqw) * var(--masthead-font-scale, 1));
  line-height: 1.02;
  letter-spacing: 0.08em;
  white-space: normal;
  transform: translateY(calc(var(--ornamental-latin-shift) * var(--masthead-font-scale, 1)));
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-centerpiece .masthead-zone--meta-column {
  padding-top: 0.14rem;
  padding-bottom: 0.14rem;
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-centerpiece .masthead-meta-line {
  font-size: calc(min(0.98rem, 1.36cqw) * var(--masthead-font-scale, 1));
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-centerpiece .masthead-ornamental-frame__asset {
  inset: 0;
  height: 100%;
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-centerpiece .masthead-ornamental-frame {
  --ornamental-copy-inset: 20% 22% 30%;
  --ornamental-title-shift: 0rem;
  --ornamental-latin-shift: 1.28rem;
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-centerpiece .masthead-ornamental-frame__copy {
  padding-top: 0.04rem;
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-centerpiece .masthead-ornamental-frame__copy .masthead-title-horizontal--paperName {
  font-size: calc(min(3.5rem, 4.9cqw) * var(--masthead-font-scale, 1));
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-centerpiece .masthead-ornamental-frame__copy .masthead-meta-line--latin {
  font-size: calc(min(1.08rem, 1.54cqw) * var(--masthead-font-scale, 1));
}

.masthead-preview--ornamental-two-row-frame .masthead-zone {
  padding-inline: 0.18rem;
}

.masthead-preview--ornamental-two-row-frame .masthead-zone:first-child {
  padding-top: 0.12rem;
  padding-bottom: 0.02rem;
}

.masthead-preview--ornamental-two-row-frame .masthead-zone:last-child {
  padding-top: 0.02rem;
  padding-bottom: 0.12rem;
}

.masthead-preview--ornamental-two-row-frame .masthead-zone--ornamental-title-frame {
  padding-inline: 0.08rem;
  padding-top: 0;
  padding-bottom: 0;
}

.masthead-preview--ornamental-two-row-frame .masthead-ornamental-frame {
  --ornamental-copy-inset: 19% 18% 17%;
  --ornamental-title-shift: -0.24rem;
  --ornamental-latin-shift: 1.24rem;
}

.masthead-preview--ornamental-two-row-frame .masthead-meta-row {
  gap: 0.34rem;
  flex-wrap: nowrap;
  padding: 0;
}

.masthead-preview--ornamental-two-row-frame .masthead-meta-chip {
  border-right: 0;
  padding: 0;
  font-size: calc(min(0.86rem, 1.22cqw) * var(--masthead-font-scale, 1));
  line-height: 1.1;
  letter-spacing: 0.04em;
}

.masthead-preview--ornamental-two-row-frame .masthead-meta-chip--publisher,
.masthead-preview--ornamental-two-row-frame .masthead-meta-chip--dateText,
.masthead-preview--ornamental-two-row-frame .masthead-meta-chip--issueNumber {
  font-family: var(--masthead-meta-font);
}

.masthead-preview--ornamental-two-row-frame .masthead-meta-chip--telegraphCode,
.masthead-preview--ornamental-two-row-frame .masthead-meta-chip--price {
  font-family: var(--masthead-typewriter-font);
}

.masthead-preview--ornamental-two-row-frame .masthead-ornamental-frame__asset {
  inset: 0;
  height: 100%;
}

.masthead-preview--ornamental-two-row-frame .masthead-ornamental-frame__copy {
  padding: 0 0.3rem;
}

.masthead-preview--ornamental-two-row-frame .masthead-ornamental-frame__copy .masthead-title-horizontal--paperName {
  font-size: calc(min(3.7rem, 5.2cqw) * var(--masthead-font-scale, 1));
  line-height: 0.94;
}

.masthead-preview--ornamental-two-row-frame .masthead-ornamental-frame__copy .masthead-meta-line--latin {
  font-size: calc(min(1.08rem, 1.5cqw) * var(--masthead-font-scale, 1));
  line-height: 1.04;
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-two-row-frame .masthead-zone:first-child {
  padding-top: 0.18rem;
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-two-row-frame .masthead-zone:last-child {
  padding-bottom: 0.18rem;
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-two-row-frame .masthead-meta-chip {
  font-size: calc(min(0.92rem, 1.28cqw) * var(--masthead-font-scale, 1));
}

.masthead-preview--horizontal-tall.masthead-preview--ornamental-two-row-frame .masthead-ornamental-frame {
  --ornamental-copy-inset: 21% 15% 15%;
  --ornamental-title-shift: -0.24rem;
  --ornamental-latin-shift: 1.48rem;
}

.masthead-preview--label-banner .masthead-newsplate__bar {
  padding: 0.06rem 0.18rem;
}

.masthead-preview--label-banner .masthead-newsplate__bar-cell {
  font-size: calc(min(0.8rem, 1.14cqw) * var(--masthead-font-scale, 1));
  letter-spacing: 0.05em;
}

.masthead-label-banner {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.16rem;
}

.masthead-label-banner__rail {
  --masthead-label-note-reserve: clamp(3.4rem, 18%, 5.2rem);
  flex: 1 1 0;
  position: relative;
  min-width: 0;
  min-height: 0;
  display: flex;
  align-items: center;
}

.masthead-label-banner__rail::before,
.masthead-label-banner__rail::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px solid var(--masthead-decoration-color);
}

.masthead-label-banner__rail--left::before,
.masthead-label-banner__rail--left::after {
  left: var(--masthead-label-note-reserve);
}

.masthead-label-banner__rail--right::before,
.masthead-label-banner__rail--right::after {
  right: var(--masthead-label-note-reserve);
}

.masthead-label-banner__rail.is-empty::before,
.masthead-label-banner__rail.is-empty::after {
  left: 0;
  right: 0;
}

.masthead-label-banner__rail::before {
  top: calc(50% - 0.12rem);
}

.masthead-label-banner__rail::after {
  top: calc(50% + 0.12rem);
}

.masthead-label-banner__note {
  position: relative;
  z-index: 1;
  width: var(--masthead-label-note-reserve);
  max-width: var(--masthead-label-note-reserve);
  padding: 0.02rem 0.08rem;
  background: transparent;
  font-size: calc(min(0.78rem, 1.12cqw) * var(--masthead-font-scale, 1));
  line-height: 1.05;
  letter-spacing: 0.05em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.masthead-label-banner__note:empty {
  display: none;
}

.masthead-label-banner__note--left {
  margin-right: auto;
  text-align: left;
}

.masthead-label-banner__note--right {
  margin-left: auto;
  text-align: right;
}

.masthead-label-banner__note--latin {
  font-family: var(--masthead-latin-font);
  font-size: calc(min(0.74rem, 1.06cqw) * var(--masthead-font-scale, 1));
  letter-spacing: 0.09em;
  font-style: italic;
}

.masthead-label-banner__plaque {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 2;
  width: fit-content;
  max-width: calc(100% - 1rem);
  min-width: min(5.8rem, calc(100% - 1rem));
  padding: 0.24rem 0.42rem 0.18rem;
  border: 2px solid var(--masthead-decoration-color);
  border-radius: 0.14rem;
  background: transparent;
  box-shadow:
    0 0 0 0.04rem transparent,
    0 0 0 0.08rem var(--masthead-decoration-color);
}

.masthead-label-banner__title {
  display: inline-block;
  width: auto;
  max-width: 100%;
  padding: 0;
  white-space: nowrap;
}

.masthead-label-banner__plaque .masthead-title-horizontal--paperName {
  font-size: calc(min(4.4rem, 6.1cqw) * var(--masthead-font-scale, 1));
  line-height: 0.92;
  letter-spacing: 0.04em;
}

.masthead-title-horizontal {
  width: 100%;
  text-align: center;
  font-size: calc(min(3rem, 4.2cqw) * var(--masthead-font-scale, 1));
  font-family: var(--masthead-title-font);
  font-weight: 400;
  letter-spacing: 0.06em;
  line-height: 1.05;
  text-shadow: 0 0.01em 0 rgba(49, 40, 29, 0.2);
}

.masthead-title-horizontal--paperName {
  font-size: calc(min(3.5rem, 4.9cqw) * var(--masthead-font-scale, 1));
}

.masthead-title-horizontal--align-left {
  text-align: left;
  padding-left: 0.18rem;
}

.masthead-title-horizontal--align-center {
  text-align: center;
}

.masthead-title-horizontal--align-right {
  text-align: right;
  padding-right: 0.18rem;
}

.masthead-meta-line--align-left {
  text-align: left;
  padding-left: 0.18rem;
}

.masthead-meta-line--align-center {
  text-align: center;
}

.masthead-meta-line--align-right {
  text-align: right;
  padding-right: 0.18rem;
}

.masthead-title-panel {
  width: 100%;
  height: 100%;
  display: grid;
  align-content: center;
  align-items: center;
  gap: 0.01rem;
}

.masthead-title-panel--title-panel-latin-top,
.masthead-title-panel--title-panel-latin-bottom {
  grid-template-rows: auto auto;
}

.masthead-title-panel .masthead-meta-line--latin {
  padding: 0;
  font-size: calc(min(1.3rem, 1.88cqw) * var(--masthead-font-scale, 1));
  line-height: 1;
  letter-spacing: 0.07em;
}

.masthead-title-panel--align-left .masthead-meta-line--latin {
  text-align: left;
  padding-left: 0.18rem;
}

.masthead-title-panel--align-center .masthead-meta-line--latin {
  text-align: center;
}

.masthead-title-panel--align-right .masthead-meta-line--latin {
  text-align: right;
  padding-right: 0.18rem;
}

.masthead-title-panel .masthead-title-horizontal--paperName {
  font-size: calc(min(3.9rem, 5.42cqw) * var(--masthead-font-scale, 1));
  line-height: 0.98;
}

.masthead-title-panel .masthead-title-horizontal {
  align-self: center;
}

.masthead-meta-column {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.38rem;
}

.masthead-meta-column__group {
  display: flex;
  flex-direction: column;
  gap: 0.04rem;
}

.masthead-meta-line--publisher,
.masthead-meta-line--dateText,
.masthead-meta-line--issueNumber {
  font-family: var(--masthead-meta-font);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.masthead-meta-line--telegraphCode,
.masthead-meta-line--price {
  font-family: var(--masthead-typewriter-font);
  font-weight: 300;
  letter-spacing: 0.04em;
}

.masthead-newsplate {
  width: 100%;
  height: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 4fr) minmax(0, 1.05fr);
  gap: 0.12rem;
  align-items: stretch;
}

.masthead-newsplate__note {
  border: 1px solid var(--masthead-decoration-color);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.03rem;
  padding: 0.08rem 0.05rem;
  min-width: 0;
}

.masthead-newsplate__note-line {
  width: 100%;
  text-align: center;
  font-family: var(--masthead-meta-font);
  font-size: calc(min(0.82rem, 1.18cqw) * var(--masthead-font-scale, 1));
  line-height: 1.08;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.masthead-newsplate__note-line--literal {
  font-weight: 700;
}

.masthead-newsplate__note-line--telegraphCode,
.masthead-newsplate__note-line--price {
  font-family: var(--masthead-typewriter-font);
  letter-spacing: 0.04em;
}

.masthead-newsplate__center {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.01rem;
  min-width: 0;
}

.masthead-newsplate__display-title {
  width: 100%;
  text-align: center;
  font-family: var(--masthead-latin-font);
  font-size: calc(min(4.4rem, 6.3cqw) * var(--masthead-font-scale, 1));
  font-weight: 700;
  line-height: 0.9;
  letter-spacing: 0.03em;
  text-transform: none;
  white-space: nowrap;
}

.masthead-newsplate__display-subtitle {
  width: 100%;
  text-align: center;
  font-family: var(--masthead-title-font);
  font-size: calc(min(2.88rem, 4.06cqw) * var(--masthead-font-scale, 1));
  line-height: 0.96;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.masthead-double-rule {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
}

.masthead-double-rule span {
  display: block;
  width: 100%;
  border-top: 1px solid var(--masthead-decoration-color);
}

.masthead-newsplate__bar {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 2.6fr) minmax(0, 1.05fr);
  align-items: center;
  gap: 0.1rem;
  padding: 0.08rem 0.18rem;
  background: var(--masthead-decoration-color);
  color: #f2e8d2;
  border: 1px solid var(--masthead-decoration-color);
}

.masthead-newsplate__bar-cell {
  min-width: 0;
  font-size: calc(min(0.9rem, 1.26cqw) * var(--masthead-font-scale, 1));
  line-height: 1;
  letter-spacing: 0.03em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.masthead-newsplate__bar-cell--left {
  text-align: left;
}

.masthead-newsplate__bar-cell--center {
  text-align: center;
}

.masthead-newsplate__bar-cell--right {
  text-align: right;
}

.masthead-title-vertical,
.masthead-meta-line,
.masthead-meta-chip,
.masthead-label-banner__note,
.masthead-title-horizontal,
.masthead-newsplate__note-line,
.masthead-newsplate__display-title,
.masthead-newsplate__display-subtitle,
.masthead-newsplate__bar-cell {
  white-space: break-spaces;
}

.masthead-label-banner__note,
.masthead-newsplate__bar-cell {
  text-overflow: clip;
}

.editor-selection-overlay {
  border: 2px solid var(--editor-valid);
  border-radius: 0;
  background: rgba(90, 122, 70, 0.12);
  pointer-events: none;
}

.editor-selection-overlay.is-invalid {
  border-color: var(--editor-danger);
  background: rgba(141, 74, 58, 0.16);
}

@media (max-width: 1200px) {
  .editor-workspace {
    grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  }

  .editor-style-grid {
    grid-template-columns: 1fr;
  }

  .editor-field--span-2 {
    grid-column: auto;
  }

  .editor-style-toolbar-row {
    align-items: stretch;
    flex-direction: column;
  }

  .editor-style-toolbar-group {
    width: 100%;
  }

  .editor-style-toolbar-group-stack {
    width: 100%;
  }
}

@media (max-width: 980px) {
  .editor-shell {
    padding-bottom: 5.6rem;
  }

  .editor-topbar,
  .editor-pagebar,
  .editor-stage-header {
    align-items: stretch;
    flex-direction: column;
  }

  .editor-topbar__meta {
    align-items: stretch;
    flex-direction: column;
  }

  .editor-topbar__actions {
    align-items: stretch;
    justify-content: flex-start;
  }

  .editor-export-field {
    min-width: 0;
  }

  .editor-project-title {
    min-width: 0;
  }

  .editor-workspace {
    grid-template-columns: 1fr;
  }

  .editor-button-row,
  .editor-sidebar-actions {
    grid-template-columns: 1fr;
  }

  .editor-sidebar,
  .editor-stage {
    min-height: 0;
  }

  body[data-mobile-dock="structure"] .editor-sidebar,
  body[data-mobile-dock="structure"] .editor-stage {
    display: none;
  }

  body[data-mobile-dock="edit"] .editor-nav,
  body[data-mobile-dock="edit"] .editor-stage {
    display: none;
  }

  body[data-mobile-dock="preview"] .editor-sidebar,
  body[data-mobile-dock="preview"] .editor-nav {
    display: none;
  }

  body[data-mobile-dock="export"] .editor-nav,
  body[data-mobile-dock="export"] .editor-stage {
    display: none;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="fit"] .editor-paper-wrap {
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="fit"] .editor-paper-viewport {
    position: relative;
    min-height: var(--paper-preview-height, 0px);
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="fit"] .editor-paper {
    position: absolute;
    top: 0;
    left: 50%;
    width: 720px;
    max-width: none;
    margin: 0;
    transform: translateX(-50%) scale(var(--paper-preview-scale, 1));
    transform-origin: top center;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="fit"] .editor-export-snapshot {
    width: 720px;
    max-width: none;
    transform: translateX(-50%) scale(var(--paper-preview-scale, 1));
    transform-origin: top center;
  }

  .editor-mobile-dock {
    position: fixed;
    left: 0.8rem;
    right: 0.8rem;
    bottom: max(0.8rem, env(safe-area-inset-bottom));
    z-index: 40;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.65rem;
    padding: 0.72rem;
    border: 1px solid rgba(76, 85, 96, 0.16);
    border-radius: 1.25rem;
    background: rgba(249, 251, 252, 0.94);
    box-shadow: 0 14px 32px rgba(34, 40, 48, 0.14);
    backdrop-filter: blur(20px) saturate(125%);
  }

  .editor-mobile-dock__button {
    padding: 0.82rem 0.9rem;
    border-radius: 0.95rem;
    background: rgba(255, 255, 255, 0.94);
    color: var(--editor-ink-soft);
  }

  .editor-mobile-dock__button.is-active {
    background: rgba(67, 76, 84, 0.94);
    color: #f7f9fb;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="actual"] .editor-paper-wrap {
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="actual"] .editor-paper-viewport {
    min-width: 720px;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="actual"] .editor-paper {
    width: 720px;
    max-width: none;
  }
}

/* UI redesign V1 shell overrides */
:root {
  --editor-ink: #302922;
  --editor-ink-soft: #7d7166;
  --editor-ink-faint: #a09488;
  --editor-paper-ui: #f7f2eb;
  --editor-paper-preview: #f1e7d6;
  --editor-warm-panel: #f5efe7;
  --editor-warm-panel-deep: #ece2d6;
  --editor-rule: rgba(132, 108, 84, 0.54);
  --editor-rule-soft: rgba(132, 108, 84, 0.18);
  --editor-accent: #c97953;
  --editor-accent-deep: #a95f3d;
  --editor-accent-soft: rgba(201, 121, 83, 0.12);
  --editor-danger: #9b5b46;
  --editor-shadow: 0 18px 38px rgba(80, 52, 32, 0.1);
  --editor-region: rgba(67, 46, 27, 0.08);
  --editor-region-selected: rgba(201, 121, 83, 0.11);
}

body {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 30%),
    linear-gradient(180deg, #f4efe8 0%, #ebe4da 100%);
}

button {
  padding: 0.7rem 0.96rem;
  border: 1px solid var(--editor-rule-soft);
  background: rgba(255, 255, 255, 0.96);
  border-radius: 0.95rem;
}

button:hover {
  background: rgba(248, 243, 238, 0.96);
}

input,
select,
textarea {
  border: 1px solid rgba(126, 108, 92, 0.16);
  background: rgba(255, 255, 255, 0.96);
  border-radius: 0.95rem;
  padding: 0.64rem 0.76rem;
}

.editor-shell {
  gap: 1.05rem;
  padding: 0.88rem;
}

.editor-topbar {
  display: grid;
  grid-template-columns: 296px minmax(0, 1fr);
  align-items: center;
  gap: 1.15rem;
  padding: 1rem 1.08rem;
  border: 1px solid var(--editor-rule-soft);
  border-radius: 1.55rem;
  background:
    linear-gradient(180deg, rgba(252, 249, 245, 0.97), rgba(247, 241, 234, 0.92));
  box-shadow: var(--editor-shadow);
  backdrop-filter: blur(16px) saturate(118%);
}

.editor-topbar__brand {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding-right: 1.08rem;
  border-right: 1px solid var(--editor-rule-soft);
}

.editor-topbar__logo {
  width: 3rem;
  height: 3rem;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 1.05rem;
  background: linear-gradient(180deg, #d28a61 0%, #c26f48 100%);
  color: #fffaf5;
  box-shadow:
    0 12px 22px rgba(195, 111, 72, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  font-family: "Noto Serif SC", "Source Han Serif", "Songti SC", serif;
  font-size: 1.22rem;
  font-weight: 700;
}

.editor-topbar__title {
  min-width: 0;
}

.editor-topbar__title h1 {
  margin: 0;
  font-family: "Noto Serif SC", "Source Han Serif", "Songti SC", serif;
  font-size: clamp(1.2rem, 1.7vw, 1.56rem);
  font-weight: 600;
  color: var(--editor-accent-deep);
}

.editor-eyebrow {
  color: #b18669;
  letter-spacing: 0.22em;
  font-size: 0.72rem;
}

.editor-topbar__center {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.editor-mode-switch,
.editor-topbar__page-current {
  flex: 0 0 auto;
}

.editor-mode-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  padding: 0.34rem;
  border: 1px solid var(--editor-rule-soft);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.editor-mode-switch__button {
  min-width: 6.6rem;
  padding: 0.68rem 1.04rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--editor-ink-soft);
  box-shadow: none;
}

.editor-mode-switch__button.is-active {
  background: linear-gradient(180deg, #d0885f 0%, #c36f48 100%);
  color: #fffaf7;
  box-shadow: 0 8px 16px rgba(195, 111, 72, 0.18);
}

.editor-topbar__page-current {
  display: grid;
  gap: 0.14rem;
  min-width: max-content;
  padding-left: 1rem;
  border-left: 1px solid var(--editor-rule-soft);
}

.editor-topbar__page-label {
  color: var(--editor-ink-faint);
  font-size: 0.74rem;
  white-space: nowrap;
}

.editor-topbar__page-current strong {
  color: var(--editor-ink);
  font-size: 0.94rem;
  font-weight: 600;
  white-space: nowrap;
}

.editor-topbar__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
}

.editor-project-title {
  min-width: 14rem;
  gap: 0.34rem;
}

.editor-project-title span,
.editor-export-field span {
  color: var(--editor-ink-faint);
  font-size: 0.78rem;
}

.editor-project-title input {
  font-weight: 600;
}

.editor-status-group {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  padding: 0.28rem;
  border: 1px solid var(--editor-rule-soft);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
}

.editor-badge {
  padding: 0.46rem 0.78rem;
  border: 1px solid rgba(132, 108, 84, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  font-size: 0.82rem;
  color: var(--editor-ink-soft);
}

.editor-topbar__actions {
  align-items: center;
  gap: 0.55rem;
}

#exportPngBtn,
.editor-primary-btn {
  border-color: rgba(169, 95, 61, 0.34);
  background: linear-gradient(180deg, #cf845c 0%, #c36f48 100%);
  color: #fffaf7;
  box-shadow: 0 10px 18px rgba(195, 111, 72, 0.2);
}

#exportPngBtn {
  padding-inline: 1.28rem;
  border-radius: 999px;
}

#exportPngBtn:hover,
.editor-primary-btn:hover {
  background: linear-gradient(180deg, #c97953 0%, #ba6842 100%);
}

#resetProjectBtn {
  color: var(--editor-danger);
  border-color: rgba(155, 91, 70, 0.18);
  background: rgba(255, 249, 247, 0.82);
}

.editor-workspace {
  grid-template-columns: 296px minmax(0, 1fr) 344px;
  gap: 1.05rem;
  padding: 0;
}

.editor-nav,
.editor-sidebar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.editor-nav-panel,
.editor-panel {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.02rem;
  border: 1px solid var(--editor-rule-soft);
  border-radius: 1.45rem;
  background:
    linear-gradient(180deg, rgba(252, 249, 244, 0.96), rgba(247, 241, 234, 0.92));
  box-shadow: var(--editor-shadow);
  backdrop-filter: blur(14px) saturate(114%);
}

.editor-section-title--context {
  display: grid;
  gap: 0.22rem;
}

.editor-panel-context-hint {
  color: var(--editor-ink-soft);
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
}

.editor-nav-panel {
  overflow: auto;
}

.editor-panel {
  overflow: auto;
}

.editor-section-title {
  padding-bottom: 0.72rem;
  border-bottom: 1px solid var(--editor-rule-soft);
  color: var(--editor-ink-faint);
  font-size: 0.74rem;
  font-family: "Noto Sans SC", "Source Han Sans", "Microsoft YaHei", sans-serif;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.editor-section h2 {
  border-bottom: 1px solid var(--editor-rule-soft);
  font-size: 0.98rem;
}

.editor-page-tabs {
  display: grid;
  gap: 0.5rem;
}

.editor-page-tab-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.42rem;
  align-items: stretch;
}

.editor-nav-list {
  display: grid;
  gap: 0.45rem;
}

.editor-nav-item {
  min-width: 0;
  position: relative;
  display: grid;
  gap: 0.14rem;
  justify-items: start;
  padding: 0.84rem 0.96rem 0.84rem 1.2rem;
  border: 1px solid transparent;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0);
  text-align: left;
  box-shadow: none;
}

.editor-nav-item::before,
.editor-page-tab::before,
.editor-region-item::before {
  content: "";
  position: absolute;
  left: 0.42rem;
  top: 50%;
  width: 0.28rem;
  height: 1.56rem;
  border-radius: 999px;
  background: var(--editor-accent);
  opacity: 0;
  transform: translateY(-50%) scaleY(0.72);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.editor-nav-item:hover {
  background: rgba(255, 255, 255, 0.58);
  border-color: rgba(132, 108, 84, 0.12);
}

.editor-nav-item.is-active {
  border-color: rgba(201, 121, 83, 0.18);
  background: rgba(255, 251, 247, 0.9);
  box-shadow: none;
}

.editor-nav-item.is-active::before,
.editor-page-tab.is-active::before,
.editor-region-item.is-active::before {
  opacity: 1;
  transform: translateY(-50%) scaleY(1);
}

.editor-nav-item__title {
  font-size: 0.92rem;
  font-weight: 600;
}

.editor-nav-item__meta {
  color: var(--editor-ink-soft);
  font-size: 0.77rem;
  line-height: 1.4;
}

.editor-page-tab {
  min-width: 0;
  position: relative;
  width: 100%;
  padding: 0.82rem 0.94rem 0.82rem 1.2rem;
  border: 1px solid transparent;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: none;
}

.editor-page-tab-delete {
  align-self: center;
  width: 2rem;
  min-width: 2rem;
  height: 2rem;
  border-color: rgba(132, 108, 84, 0.12);
  background: rgba(255, 255, 255, 0.52);
}

.editor-page-tab-delete:hover {
  background: rgba(255, 247, 243, 0.92);
}

.editor-page-tab:hover {
  background: rgba(255, 255, 255, 0.58);
  border-color: rgba(132, 108, 84, 0.12);
}

.editor-page-tab.is-active,
.editor-region-item.is-active {
  border-color: rgba(201, 121, 83, 0.18);
  background: rgba(255, 251, 247, 0.9);
  box-shadow: none;
}

.editor-page-actions {
  display: grid;
  gap: 0.55rem;
}

.editor-page-actions button,
.editor-sidebar-actions button {
  width: 100%;
}

.editor-meta-list div {
  border-bottom: 1px dotted rgba(132, 108, 84, 0.26);
}

.editor-meta-list dt {
  color: var(--editor-ink-faint);
}

.editor-hint {
  color: var(--editor-ink-soft);
}

.editor-sidebar-actions {
  grid-template-columns: 1fr;
}

.editor-nav-footer {
  margin-top: auto;
  display: grid;
  gap: 0.75rem;
  padding-top: 0.95rem;
  border-top: 1px solid var(--editor-rule-soft);
}

.editor-nav-footer__entry .editor-nav-item {
  width: 100%;
}

.editor-region-list {
  gap: 0.35rem;
}

.editor-region-item {
  position: relative;
  padding: 0.76rem 0.84rem 0.76rem 1.2rem;
  border: 1px solid transparent;
  border-radius: 0.95rem;
  background: rgba(255, 255, 255, 0.05);
}

.editor-region-item--masthead {
  border-style: dashed;
}

.editor-region-item--masthead .editor-region-item__title {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.editor-region-item--masthead .editor-region-item__title::before {
  content: "";
  width: 0.46rem;
  height: 0.46rem;
  border-radius: 999px;
  background: var(--editor-accent);
  box-shadow: 0 0 0 0.18rem rgba(201, 121, 83, 0.16);
}

.editor-region-item:hover {
  background: rgba(255, 255, 255, 0.52);
  border-color: rgba(132, 108, 84, 0.12);
}

.editor-empty-state {
  border: 1px dashed rgba(132, 108, 84, 0.28);
  background: rgba(255, 251, 247, 0.72);
}

.editor-inspector-group {
  display: grid;
  gap: 0.95rem;
}

.editor-inspector-group.hidden {
  display: none;
}

.editor-style-card {
  border: 1px solid rgba(132, 108, 84, 0.14);
  background: rgba(255, 252, 248, 0.78);
}

.editor-stage {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 0.95rem;
}

.editor-stage-header {
  border: 1px solid var(--editor-rule-soft);
  border-radius: 1.45rem;
  background:
    linear-gradient(180deg, rgba(251, 248, 243, 0.86), rgba(246, 240, 233, 0.76));
  box-shadow: var(--editor-shadow);
  padding: 0.95rem 1.08rem;
  align-items: center;
}

.editor-stage-header h2 {
  font-size: clamp(1.14rem, 1.4vw, 1.34rem);
}

.editor-stage-badges {
  align-items: center;
  padding: 0.28rem;
  border: 1px solid var(--editor-rule-soft);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.56);
}

.editor-mobile-preview-toggle {
  display: none;
  align-items: center;
  gap: 0.45rem;
  padding: 0.3rem;
  border: 1px solid var(--editor-rule-soft);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
}

.editor-mobile-preview-toggle__button {
  padding: 0.48rem 0.76rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--editor-ink-soft);
  font-size: 0.78rem;
  font-weight: 600;
  box-shadow: none;
}

.editor-mobile-preview-toggle__button.is-active {
  background: rgba(201, 121, 83, 0.16);
  color: var(--editor-accent-deep);
}

.editor-paper-wrap {
  border: 1px solid var(--editor-rule-soft);
  border-radius: 1.6rem;
  padding: 1.22rem;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.52), rgba(255, 255, 255, 0)),
    linear-gradient(180deg, rgba(245, 239, 232, 0.96), rgba(236, 229, 219, 0.96));
  box-shadow: 0 18px 36px rgba(80, 52, 32, 0.08);
}

@media (max-width: 1400px) {
  .editor-topbar {
    grid-template-columns: 280px minmax(0, 1fr);
  }

  .editor-workspace {
    grid-template-columns: 272px minmax(0, 1fr) 320px;
  }
}

@media (max-width: 1200px) {
  .editor-topbar {
    grid-template-columns: 1fr;
  }

  .editor-topbar__meta {
    justify-content: flex-start;
  }

  .editor-topbar__credit {
    margin-top: -0.12rem;
  }

  .editor-topbar__brand,
  .editor-topbar__meta {
    padding-left: 0;
    border-left: 0;
    padding-right: 0;
    border-right: 0;
  }

  .editor-workspace {
    grid-template-columns: 260px minmax(0, 1fr) 300px;
  }
}

@media (max-width: 980px) {
  .editor-shell {
    padding: 0.65rem 0.65rem 5.6rem;
  }

  .editor-topbar__meta,
  .editor-stage-header {
    align-items: stretch;
    flex-direction: column;
  }

  .editor-topbar {
    gap: 0.82rem;
    padding: 0.78rem 0.82rem;
    border-radius: 1.22rem;
  }

  .editor-topbar__brand {
    gap: 0.68rem;
    padding-right: 0;
    border-right: 0;
  }

  .editor-topbar__logo {
    width: 2.45rem;
    height: 2.45rem;
    border-radius: 0.88rem;
    font-size: 1rem;
  }

  .editor-topbar__title h1 {
    font-size: 1.28rem;
  }

  .editor-eyebrow {
    font-size: 0.64rem;
    letter-spacing: 0.18em;
  }

  .editor-project-title {
    min-width: 0;
  }

  .editor-topbar__actions {
    justify-content: flex-start;
    gap: 0.42rem;
  }

  .editor-topbar__actions button,
  .editor-status-group .editor-badge {
    font-size: 0.78rem;
  }

  .editor-topbar__actions button {
    padding: 0.52rem 0.74rem;
    border-radius: 0.82rem;
  }

  .editor-topbar__credit {
    font-size: 0.62rem;
    letter-spacing: 0.1em;
  }

  #exportPngBtn {
    padding-inline: 0.96rem;
  }

  .editor-status-group {
    gap: 0.32rem;
    padding: 0.2rem;
  }

  .editor-badge {
    padding: 0.38rem 0.6rem;
  }

  .editor-project-title,
  .editor-export-field {
    min-width: 0;
  }

  .editor-workspace {
    grid-template-columns: 1fr;
    position: relative;
    isolation: isolate;
    --editor-mobile-structure-drawer-width: min(52vw, 17.4rem);
    --editor-mobile-dock-float-height: 4.9rem;
  }

  .editor-nav {
    position: fixed;
    top: 0.72rem;
    left: 0;
    bottom: calc(var(--editor-mobile-dock-float-height) + max(0.72rem, env(safe-area-inset-bottom)));
    width: var(--editor-mobile-structure-drawer-width);
    max-width: calc(100% - 4rem);
    z-index: 46;
    opacity: 0;
    pointer-events: none;
    transform: translateX(calc(-100% - 0.9rem));
    gap: 0;
    padding: 0.88rem 0.84rem 3.4rem;
    border: 1px solid var(--editor-rule-soft);
    border-radius: 1.18rem;
    background:
      linear-gradient(180deg, rgba(252, 249, 244, 0.97), rgba(247, 241, 234, 0.94));
    box-shadow: 0 16px 30px rgba(80, 52, 32, 0.18);
    backdrop-filter: blur(16px) saturate(116%);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    transition:
      transform 220ms ease,
      opacity 180ms ease;
  }

  body[data-mobile-structure-drawer="open"] .editor-nav {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0);
  }

  body[data-mobile-dock="edit"] .editor-nav,
  body[data-mobile-dock="preview"] .editor-nav,
  body[data-mobile-dock="export"] .editor-nav,
  body[data-mobile-dock="structure"] .editor-nav {
    display: flex;
  }

  .editor-nav-panel {
    height: auto;
    flex: 0 0 auto;
    gap: 0.64rem;
    padding: 0.74rem 0 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
    overflow: visible;
  }

  .editor-nav-panel:first-child {
    padding-top: 0;
  }

  .editor-nav-panel + .editor-nav-panel {
    margin-top: 0.72rem;
    border-top: 1px solid var(--editor-rule-soft);
  }

  .editor-nav-panel--pages {
    gap: 0.5rem;
  }

  .editor-nav-panel--pages .editor-section-title {
    padding-bottom: 0.38rem;
  }

  #setupNavPanel {
    flex: 1 1 auto;
    min-height: 0;
  }

  #setupNavPanel > .editor-section:first-of-type {
    gap: 0.38rem;
    padding-top: 0.12rem;
  }

  #setupNavPanel > .editor-section:first-of-type .editor-meta-list {
    gap: 0.24rem;
  }

  #setupNavPanel > .editor-section:first-of-type .editor-meta-list div {
    padding-bottom: 0.2rem;
  }

  #setupNavPanel > .editor-section:first-of-type .editor-hint {
    font-size: 0.68rem;
    line-height: 1.36;
  }

  #setupNavPanel .editor-section--plain {
    flex: 1 1 auto;
  }

  #setupNavPanel .editor-sidebar-actions {
    margin-top: auto;
    padding-top: 0.52rem;
    padding-bottom: 0.72rem;
    border-top: 1px solid rgba(132, 108, 84, 0.14);
    margin-top: 0.82rem;
  }

  #editorNavPanel {
    flex: 1 1 auto;
    min-height: 0;
  }

  #editorNavPanel .editor-nav-footer {
    margin-top: 0.82rem;
    padding-top: 0.72rem;
    padding-bottom: 0.72rem;
    border-top: 1px solid rgba(132, 108, 84, 0.14);
  }

  #editorNavPanel > .editor-section:first-of-type {
    gap: 0.34rem;
    padding-top: 0.08rem;
  }

  #editorNavPanel > .editor-section:first-of-type .editor-meta-list {
    gap: 0.22rem;
  }

  #editorNavPanel > .editor-section:first-of-type .editor-meta-list div {
    gap: 0.5rem;
    padding-bottom: 0.18rem;
  }

  #editorNavPanel > .editor-section:first-of-type .editor-meta-list dt,
  #editorNavPanel > .editor-section:first-of-type .editor-meta-list dd {
    font-size: 0.72rem;
    line-height: 1.28;
  }

  #editorNavPanel > .editor-section:first-of-type .editor-meta-list dd {
    max-width: 56%;
    overflow-wrap: anywhere;
  }

  .editor-mobile-structure-scrim {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: calc(var(--editor-mobile-dock-float-height) + max(0.72rem, env(safe-area-inset-bottom)));
    z-index: 42;
    display: block;
    border: 0;
    border-radius: 0;
    background: rgba(54, 42, 30, 0.12);
    box-shadow: none;
    cursor: pointer;
  }

  .editor-mobile-structure-toggle {
    position: fixed;
    left: 0.88rem;
    bottom: calc(var(--editor-mobile-dock-float-height) + 1rem + max(0.72rem, env(safe-area-inset-bottom)));
    z-index: 47;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.62rem;
    min-height: 2.62rem;
    padding: 0;
    border: 1px solid rgba(132, 108, 84, 0.18);
    border-radius: 999px;
    background: rgba(251, 248, 243, 0.92);
    box-shadow: 0 10px 22px rgba(80, 52, 32, 0.14);
    backdrop-filter: blur(18px) saturate(122%);
    transition:
      background-color 180ms ease,
      border-color 180ms ease,
      box-shadow 180ms ease,
      transform 180ms ease;
  }

  .editor-mobile-structure-toggle::before {
    content: "☰";
    font-size: 1rem;
    line-height: 1;
    color: currentColor;
  }

  .editor-mobile-structure-toggle.is-open {
    background: linear-gradient(180deg, #d0885f 0%, #c36f48 100%);
    border-color: rgba(169, 95, 61, 0.34);
    color: #fffaf7;
    box-shadow: 0 12px 24px rgba(195, 111, 72, 0.26);
    transform: translateX(calc(var(--editor-mobile-structure-drawer-width) - 0.66rem));
  }

  .editor-mobile-structure-toggle.is-open::before {
    content: "✕";
    font-size: 0.92rem;
  }

  .editor-mobile-structure-toggle__text {
    display: none;
  }

  body[data-mobile-dock="edit"] .editor-stage {
    display: none;
  }

  body[data-mobile-dock="preview"] .editor-sidebar {
    display: none;
  }

  body[data-mobile-dock="export"] .editor-stage {
    display: none;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="fit"] .editor-paper-wrap {
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="fit"] .editor-paper-viewport {
    position: relative;
    min-height: var(--paper-preview-height, 0px);
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="fit"] .editor-paper {
    position: absolute;
    top: 0;
    left: 50%;
    width: 720px;
    max-width: none;
    margin: 0;
    transform: translateX(-50%) scale(var(--paper-preview-scale, 1));
    transform-origin: top center;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="fit"] .editor-export-snapshot {
    width: 720px;
    max-width: none;
    transform: translateX(-50%) scale(var(--paper-preview-scale, 1));
    transform-origin: top center;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="actual"] .editor-paper-wrap {
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="actual"] .editor-paper-viewport {
    min-width: 720px;
  }

  body[data-mobile-dock="preview"][data-mobile-preview-mode="actual"] .editor-paper {
    width: 720px;
    max-width: none;
  }

  .editor-mobile-dock {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border: 1px solid var(--editor-rule-soft);
    border-radius: 1.2rem;
    padding: 0.28rem;
    background: rgba(251, 248, 243, 0.94);
    box-shadow: 0 14px 32px rgba(80, 52, 32, 0.14);
  }

  .editor-mobile-dock__button {
    min-height: 2.72rem;
    border-radius: 0.95rem;
    border-color: transparent;
    background: rgba(255, 255, 255, 0.8);
  }

  .editor-mobile-dock__button.is-active {
    background: linear-gradient(180deg, #d0885f 0%, #c36f48 100%);
    color: #fffaf7;
  }

  .editor-mobile-preview-toggle {
    display: inline-flex;
    width: fit-content;
  }

  .editor-section-title {
    padding-bottom: 0.48rem;
  }

  .editor-section {
    gap: 0.6rem;
  }

  .editor-page-tabs,
  .editor-nav-list,
  .editor-region-list {
    gap: 0.28rem;
  }

  .editor-page-tab-row {
    gap: 0.28rem;
  }

  .editor-page-tab,
  .editor-nav-item,
  .editor-region-item {
    padding: 0.6rem 0.72rem 0.6rem 1rem;
    border-radius: 0.86rem;
  }

  .editor-nav-item::before,
  .editor-page-tab::before,
  .editor-region-item::before {
    left: 0.3rem;
    width: 0.22rem;
    height: 1.18rem;
  }

  .editor-page-tab__title,
  .editor-nav-item__title,
  .editor-region-item__title {
    font-size: 0.82rem;
  }

  .editor-page-tab__meta,
  .editor-nav-item__meta,
  .editor-region-item__meta {
    font-size: 0.67rem;
    line-height: 1.28;
  }

  .editor-page-tab-delete {
    width: 1.72rem;
    min-width: 1.72rem;
    height: 1.72rem;
    border-radius: 0.7rem;
    font-size: 0.92rem;
  }

  .editor-page-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.34rem;
  }

  .editor-page-actions button {
    padding: 0.46rem 0.56rem;
    border-radius: 0.78rem;
    font-size: 0.72rem;
  }

  .editor-meta-list {
    gap: 0.4rem;
  }

  .editor-meta-list dt,
  .editor-meta-list dd {
    font-size: 0.76rem;
  }

  .editor-meta-list div {
    padding-bottom: 0.34rem;
  }

  .editor-nav-footer {
    gap: 0.56rem;
    padding-top: 0.72rem;
  }
}
