:root {
  --paper: #f7f5f0;
  --ink: #302a26;
  --muted: #8b8077;
  --line: #e6e0d7;
  --red: #85332d;
  --sand: #ece6dc;
  --white: #fffefa;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  font-family:
    -apple-system, BlinkMacSystemFont, "PingFang TC", "Noto Sans", sans-serif;
  background: var(--paper);
  color: var(--ink);
  font-size: 14px;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
  border: 1px solid var(--line);
  background: var(--white);
  padding: 10px 16px;
  border-radius: 7px;
  color: var(--ink);
}
button:hover {
  border-color: #ac8c77;
  background: #f1ece4;
}
button.primary {
  background: var(--red);
  border-color: var(--red);
  color: white;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
a {
  color: var(--red);
}
input,
textarea,
select {
  border: 1px solid var(--line);
  background: var(--white);
  padding: 11px 12px;
  border-radius: 6px;
  color: var(--ink);
  width: 100%;
}
textarea {
  resize: vertical;
  line-height: 1.8;
  min-height: 110px;
}
input:focus,
textarea:focus,
select:focus {
  outline: 2px solid #c8a18b;
  outline-offset: 1px;
}
label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin: 14px 0 7px;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-family: Georgia, "Songti TC", serif;
  font-size: 38px;
  font-weight: 400;
  letter-spacing: -1px;
  margin-bottom: 12px;
}
h2 {
  font-family: Georgia, "Songti TC", serif;
  font-size: 25px;
  font-weight: 400;
}
h3 {
  font-size: 16px;
  font-weight: 500;
}
p {
  line-height: 1.8;
}
small,
.muted {
  color: var(--muted);
}
.shell {
  display: grid;
  grid-template-columns: 230px 1fr;
  min-height: 100vh;
}
.sidebar {
  overflow-y: auto;
  background: #eee9e0;
  border-right: 1px solid var(--line);
  padding: 32px 20px;
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
}
.wordmark {
  font-family: Georgia, serif;
  font-size: 24px;
  letter-spacing: -1px;
  margin: 0 10px 5px;
}
.edition {
  font-size: 9px;
  letter-spacing: 3px;
  color: var(--muted);
  margin: 0 10px 30px;
}
.brand-picker {
  margin-bottom: 26px;
  display: flex;
  gap: 5px;
}
.brand-picker button {
  padding: 8px;
}
.nav-label {
  font-size: 10px;
  letter-spacing: 2px;
  color: var(--muted);
  margin: 15px 12px 8px;
}
.nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.nav button {
  text-align: left;
  border: 0;
  background: transparent;
  padding: 12px 13px;
  font-size: 13px;
}
.nav button.active {
  background: #ded4c6;
  color: #702f29;
}
.nav .icon {
  display: inline-block;
  width: 27px;
  color: #9a8878;
}
.local {
  margin-top: auto;
  padding: 22px 10px 0;
  border-top: 1px solid #ddd3c6;
  font-size: 11px;
  color: var(--muted);
}
.dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #7e9174;
  margin-right: 6px;
}
.main {
  min-width: 0;
}
.topbar {
  height: 72px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 42px;
  font-size: 12px;
  color: var(--muted);
}
.topbar strong {
  color: var(--ink);
  font-weight: 500;
}
.workspace {
  padding: 35px 42px 65px;
  max-width: 1640px;
  margin: auto;
}
.eyebrow {
  font-size: 10px;
  letter-spacing: 3px;
  color: var(--red);
  margin-bottom: 15px;
}
.heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 26px;
  gap: 20px;
}
.heading p {
  margin: 0;
  color: var(--muted);
}
.hero {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  min-height: 355px;
  background: #e9e0d3;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 28px;
}
.hero-text {
  padding: 38px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.hero h2 {
  font-size: 39px;
  line-height: 1.35;
  max-width: 410px;
}
.hero-text p {
  color: #76685d;
  max-width: 350px;
  font-size: 13px;
}
.hero-image {
  display: flex;
  min-width: 0;
  background: #722f28;
  position: relative;
}
.hero-image img {
  width: 100%;
  height: 355px;
  object-fit: contain;
  object-position: center 30%;
}
.hero-image .caption {
  position: absolute;
  bottom: 22px;
  left: 24px;
  font-size: 10px;
  letter-spacing: 2px;
  color: white;
}
.hero-image.empty {
  align-items: center;
  justify-content: center;
  color: #e0c0a3;
  font-family: Georgia, serif;
  font-size: 70px;
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 32px;
}
.stat {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 22px;
  border-radius: 8px;
}
.stat span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.stat strong {
  display: block;
  font-family: Georgia, serif;
  font-size: 32px;
  font-weight: 400;
  margin: 9px 0 3px;
}
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 26px 0 17px;
}
.section-head h2 {
  margin: 0;
}
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(175px, 1fr));
  gap: 18px;
}
.asset {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  text-align: left;
  padding: 0;
  position: relative;
  min-width: 0;
}
.gallery.character-baseline-gallery {
  grid-template-columns: none;
  grid-auto-flow: column;
  grid-auto-columns: minmax(175px, 220px);
  overflow-x: auto;
  padding-bottom: 12px;
}
.social-feed { margin-top: 32px; }
.caption-underlay-options { display:grid; grid-template-columns:repeat(auto-fit,minmax(200px,1fr)); gap:16px; margin:20px 0; }
.caption-underlay-options button[aria-pressed="true"] { outline:3px solid #843329; }
.caption-demo { display:flex; align-items:center; height:120px; padding:20px; margin-bottom:12px; color:white; font-size:24px; font-weight:700; background:linear-gradient(140deg,#a3957b,#53645b); }
.caption-demo.with-gradient { background:linear-gradient(to right,rgba(65,3,9,.95),rgba(65,3,9,0) 65%),linear-gradient(140deg,#a3957b,#53645b); }
.caption-demo.with-solid { background:linear-gradient(to right,#650e15 0%,#650e15 62%,transparent 62%),linear-gradient(140deg,#a3957b,#53645b); }
.social-feed-placeholder {
  min-height: 260px;
  padding: 32px 24px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 12px;
  background: var(--white);
}
.social-feed-placeholder h3 { margin: 16px 0 8px; }
.social-feed-placeholder p { margin: 0 0 12px; }
.social-feed-placeholder small { color: var(--muted); }
.character-baseline-gallery .asset img {
  object-fit: contain;
  background: var(--white);
}
.asset img {
  width: 100%;
  height: 230px;
  object-fit: cover;
  display: block;
}
.asset .info {
  padding: 13px;
}
.asset .info strong {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 12px;
  font-weight: 500;
  margin-bottom: 7px;
}
.asset .info small {
  font-size: 10px;
}
.asset .mark {
  position: absolute;
  top: 9px;
  left: 9px;
  background: #fffaf0;
  padding: 5px 8px;
  border-radius: 4px;
  font-size: 10px;
}
.asset.selected {
  outline: 3px solid var(--red);
}
.toolbar {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 22px;
}
.toolbar input {
  flex: 1;
}
.toolbar select {
  max-width: 220px;
}
.pill {
  font-size: 10px;
  display: inline-block;
  border-radius: 20px;
  padding: 5px 10px;
  background: #eee6da;
  color: #796353;
  line-height: 1.4;
}
.pill.green {
  background: #e8edde;
  color: #60704e;
}
.pill.red {
  background: #f1dfda;
  color: #85332d;
}
.panel {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 26px;
  border-radius: 9px;
}
.grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}
.split {
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 22px;
}
.doclist {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.doclist button {
  text-align: left;
  line-height: 1.5;
}
.doclist button.active {
  background: #eee4d8;
  border-color: #b79b85;
}
.editor {
  min-height: 440px;
  font-size: 13px;
}
.actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  flex-wrap: wrap;
}
.empty-state {
  text-align: center;
  border: 1px dashed #cfc3b5;
  border-radius: 10px;
  padding: 70px 30px;
  color: var(--muted);
}
.empty-state h2 {
  color: var(--ink);
}
.empty-state .symbol {
  font-family: Georgia;
  font-size: 60px;
  color: #b69b86;
  margin-bottom: 20px;
}
.chat {
  max-width: 900px;
  margin: auto;
}
.messages {
  min-height: 330px;
  max-height: 54vh;
  overflow: auto;
  padding: 10px 0 20px;
}
.bubble {
  padding: 17px 20px;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 10px;
  margin: 12px 0;
  max-width: 90%;
  line-height: 1.8;
  white-space: pre-wrap;
}
.bubble.user {
  margin-left: auto;
  background: #ede3d6;
  border: 0;
}
.bubble .role {
  display: block;
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--muted);
  margin-bottom: 6px;
}
.composer {
  padding: 18px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 10px;
}
.composer textarea {
  border: 0;
  min-height: 95px;
  background: transparent;
  padding: 0;
}
.composer small {
  font-size: 11px;
}
.attachment {
  font-size: 11px;
  background: var(--sand);
  padding: 7px 12px;
  border-radius: 5px;
  display: inline-block;
  margin: 0 8px 8px 0;
}
.job {
  border: 1px solid var(--line);
  padding: 22px;
  border-radius: 8px;
  background: var(--white);
  margin-bottom: 13px;
}
.job header {
  display: flex;
  justify-content: space-between;
  gap: 15px;
}
.job h3 {
  margin-bottom: 8px;
}
.job img {
  max-width: 210px;
  max-height: 300px;
  display: block;
  margin-top: 20px;
  border-radius: 5px;
}
.job pre {
  white-space: pre-wrap;
  max-height: 250px;
  overflow: auto;
  font-size: 12px;
  color: var(--muted);
}
.pipeline {
  border-top: 3px solid var(--red);
}
.steps {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 16px 0;
}
.steps span {
  font-size: 11px;
  color: #89735f;
}
.settings {
  max-width: 970px;
}
.settings .panel {
  margin-bottom: 22px;
}
.settings h2 {
  font-size: 22px;
}
.row {
  display: flex;
  gap: 16px;
}
.row > div {
  flex: 1;
}
code {
  font-family: monospace;
  font-size: 11px;
  background: var(--sand);
  padding: 3px 5px;
}
.check {
  display: flex;
  gap: 10px;
  align-items: center;
}
.check input {
  width: auto;
}
.banner {
  padding: 13px 18px;
  background: #ede5d8;
  border: 1px solid #ddcdbb;
  border-radius: 6px;
  color: #806950;
  font-size: 12px;
  margin-bottom: 20px;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 12px;
  max-width: 940px;
  width: 90%;
  padding: 30px;
  background: var(--paper);
  color: var(--ink);
  max-height: 92vh;
  overflow: auto;
}
.video-busy-overlay { position: fixed; inset: 0; z-index: 10000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; background: rgb(250 248 244 / 94%); padding: 32px; text-align: center; cursor: wait; }
.video-text-editor textarea[readonly] { background: #eeeae3; }
#video-board-previews pre { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 13px; }
dialog::backdrop {
  background: #241a1866;
  backdrop-filter: blur(4px);
}
.modal-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}
.modal-layout > img {
  width: 100%;
  max-height: 65vh;
  object-fit: contain;
  background: #e7ded2;
  border-radius: 7px;
}
.close {
  float: right;
  margin-bottom: 10px;
}
.preview {
  width: 100%;
  max-height: 500px;
  object-fit: contain;
}
.upload-input {
  max-width: 270px;
  font-size: 11px;
  padding: 7px;
}
#toast {
  position: fixed;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  padding: 13px 23px;
  color: white;
  background: #302a26;
  border-radius: 8px;
  z-index: 100;
  display: none;
  max-width: 90vw;
}
.loading {
  padding: 90px;
  text-align: center;
  color: var(--muted);
}
details {
  margin-top: 15px;
}
summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
}
.mono {
  font-family: monospace;
  font-size: 12px;
}
@media (max-width: 1050px) {
  .shell {
    grid-template-columns: 190px 1fr;
  }
  .workspace {
    padding: 28px 25px;
  }
  .topbar {
    padding: 0 25px;
  }
  .hero-text {
    padding: 25px;
  }
  .hero h2 {
    font-size: 30px;
  }
  .grid2 {
    grid-template-columns: 1fr;
  }
  .split {
    grid-template-columns: 220px 1fr;
  }
}
@media (max-width: 720px) {
  .shell {
    display: block;
  }
  .sidebar {
    position: relative;
    height: auto;
    padding: 18px;
  }
  .edition,
  .local,
  .nav-label {
    display: none;
  }
  .wordmark {
    margin-bottom: 18px;
  }
  .brand-picker {
    margin-bottom: 12px;
  }
  .nav {
    flex-direction: row;
    overflow-x: auto;
  }
  .nav button {
    white-space: nowrap;
  }
  .topbar {
    height: 48px;
  }
  .workspace {
    padding: 24px 16px;
  }
  .hero {
    grid-template-columns: 1fr;
  }
  .hero-image {
    display: none;
  }
  .hero h2 {
    max-width: none;
  }
  .stats {
    grid-template-columns: 1fr 1fr;
  }
  .split,
  .modal-layout {
    grid-template-columns: 1fr;
  }
  .gallery {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  .asset img {
    height: 190px;
  }
  .toolbar {
    flex-wrap: wrap;
  }
  .toolbar select {
    max-width: none;
  }
  .heading {
    align-items: flex-start;
  }
  h1 {
    font-size: 30px;
  }
  .row {
    flex-direction: column;
  }
  .doclist {
    max-height: 200px;
    overflow: auto;
  }
}
:root {
  --wiki-border: #e5dfd6;
}
.wiki-reader {
  line-height: 1.9;
  overflow-wrap: anywhere;
}
.wiki-reader table {
  border-collapse: collapse;
  width: 100%;
}
.wiki-reader td,
.wiki-reader th {
  padding: 10px;
  border: 1px solid var(--wiki-border);
  text-align: left;
}
.wiki-reader pre {
  white-space: pre-wrap;
}
.wiki-reader h1 {
  font-size: 32px;
}
.wiki-reader h2 {
  margin-top: 32px;
  font-size: 24px;
}
.product-cover {
  width: 100%;
  height: 240px;
  object-fit: contain;
}
select[multiple] {
  min-height: 120px;
}
:root {
  --poster-accent: #87372f;
}
.reference-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  max-height: 360px;
  overflow: auto;
  padding: 4px;
}
.reference-tile {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 6px;
  text-align: left;
}
.reference-tile img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  border-radius: 5px;
}
.reference-tile span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
}
.reference-tile small {
  font-size: 12px;
}
.reference-tile.selected {
  outline: 2px solid var(--poster-accent);
  background: #f3e5de;
}
.reference-picker {
  margin: 20px 0;
}
#poster-chat .logo-thumb-grid {display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:12px;max-height:300px;overflow:auto;margin:16px 0;}
#poster-chat .logo-tile {min-width:0;padding:10px;font-size:13px;overflow-wrap:anywhere;}
#poster-chat .logo-thumb {display:flex;height:76px;align-items:center;justify-content:center;background:repeating-conic-gradient(#ddd 0% 25%,#fff 0% 50%) 0 / 16px 16px;margin-bottom:8px;overflow:hidden;}
#poster-chat .logo-thumb img {display:block;width:100%;height:76px;max-width:100%;max-height:76px;object-fit:contain;}
#poster-chat .logo-position-grid {display:grid;grid-template-columns:repeat(2,110px);gap:10px;margin:16px 0;}
.logo-position-demo {display:block;position:relative;width:70px;height:48px;border:1px solid #a99c8e;margin:0 auto 6px;background:#fff;}
.logo-position-demo i {position:absolute;font-size:9px;font-style:normal;}
.logo-position-demo.top-left i {top:3px;left:3px;}.logo-position-demo.top-right i {top:3px;right:3px;}
.logo-position-demo.bottom-left i {bottom:3px;left:3px;}.logo-position-demo.bottom-right i {bottom:3px;right:3px;}
#logo-advanced {margin:16px 0;max-width:460px;}
#poster-chat .copy-answer {min-height:100px;height:110px;}
#poster-chat .copy-answer[hidden] {display:none;}
#poster-chat .copy-answer:disabled {background:#e8e5e0;color:#78736c;border-color:#d5d0c8;cursor:not-allowed;opacity:1;}
#poster-chat .copy-answer:disabled::placeholder {color:#78736c;opacity:1;}
#poster-chat #questions-form:has(.copy-answer) label[for=focus-answer] {font-size:16px;font-weight:500;}
.poster-progress {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  list-style: none;
  padding: 0;
  color: #82796e;
  font-size: 14px;
}
.poster-progress li { padding: 8px 10px; border-radius: 8px; }
.poster-progress .current { background: #eee4d7; color: #89392f; font-weight: 700; }
.poster-progress .done { color: #526348; }
.poster-progress li:has(button) {padding:0;}
.poster-progress button {padding:8px 10px;border:0;background:transparent;color:inherit;font:inherit;border-radius:8px;cursor:pointer;}
.poster-progress button:hover:not(:disabled) {background:#eee4d7;text-decoration:underline;}
.poster-progress button:focus-visible {outline:3px solid #397a9d;outline-offset:2px;}
.poster-progress button:disabled {cursor:wait;opacity:.55;}
.video-camera-picker {margin:20px 0;}
.video-camera-picker > span {color:var(--muted);}
:is(#video-camera-options,#video-era-options,#video-speech-options) {margin:0;border:1px solid #e4ddd3;border-radius:10px;background:#fff;}
:is(#video-camera-options,#video-era-options,#video-speech-options) summary {padding:16px;color:inherit;cursor:pointer;}
.video-camera-option {padding:0 10px;}
.video-camera-option button {width:100%;text-align:left;border:0;background:transparent;}
.video-camera-option button:hover,.video-camera-option button:focus-visible {background:#eee4d7;}
.video-camera-option button[aria-pressed=true] {color:#89392f;font-weight:700;}
.video-camera-option [role=tooltip] {display:none;margin:0;padding:12px 16px;background:#f5efe6;color:#403831;border-radius:8px;}
.video-camera-option:hover [role=tooltip],.video-camera-option:focus-within [role=tooltip] {display:block;}
:is(#video-camera-selected,#video-era-selected,#video-speech-selected) {margin:10px 0;}
.poster-step-title { outline: none; }
#poster-chat label[for="focus-answer"],
#poster-chat label[for="logo-choice"],
#poster-chat #topic-form > label {
  display: block;
  font-size: clamp(1.25rem, 1.1rem + .5vw, 1.5rem);
  font-weight: 700;
  line-height: 1.55;
  color: #292522;
  margin: 16px 0 12px;
  overflow-wrap: anywhere;
}
.harness-text { white-space: pre-wrap; overflow-wrap: anywhere; }
.harness-hub-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; align-items: start; }
.harness-hub-grid .harness-card { min-width: 0; overflow-wrap: anywhere; }
.harness-hub-grid .harness-card-empty { order: 1; }
.harness-hub-grid .diagram-canvas { height: 280px; display: flex; align-items: center; justify-content: center; }
.harness-hub-grid .diagram-canvas img { max-height: 254px; max-width: 100%; }
.harness-import-note { margin-top: 22px; }
@media (max-width: 900px) { .harness-hub-grid { grid-template-columns: minmax(0, 1fr); } }
.harness-diagram { margin: 20px 0; }
.diagram-canvas { position: relative; background: #fff; border: 1px solid #ded7cd; border-radius: 12px; padding: 12px; }
.diagram-canvas img { display: block; width: auto; max-width: 100%; height: auto; max-height: 320px; margin: 0 auto; object-fit: contain; }
.diagram-canvas img { cursor: zoom-in; }
.diagram-canvas img:focus-visible { outline: 2px solid #843329; outline-offset: 4px; }
.diagram-lens { position: absolute; z-index: 3; pointer-events: none; overflow: hidden; background: white; border: 2px solid #843329; border-radius: 12px; box-shadow: 0 8px 28px #241a1830; }
.diagram-lens[hidden] { display: none; }
.diagram-lens svg { display: block; width: 100%; height: 100%; }
#poster-chat .focus-more { background: #e3edf3; color: #234f6d; border-color: #9fb9ca; }
#focus-extra { margin-top: 16px; padding: 20px; border: 1px solid #9fb9ca; border-radius: 12px; background: #f0f5f8; }
.question-visuals { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 16px; margin: 20px 0 12px; }
.question-visuals figure { margin: 0; min-width: 0; border: 1px solid #ded7cd; border-radius: 12px; overflow: hidden; }
.question-visuals img { display: block; width: 100%; height: 240px; object-fit: contain; background: #eee9e1; }
.question-visuals figcaption { padding: 12px; font-size: 16px; font-weight: 600; }
.question-visual-choice { padding: 0; overflow: hidden; text-align: left; border: 2px solid #ded7cd; border-radius: 12px; min-width: 0; }
.question-visual-choice span { display: block; padding: 12px; font-size: 16px; font-weight: 700; }
.question-visual-choice[aria-pressed="true"] { border-color: #87372e; background: #efe2d7; box-shadow: 0 0 0 2px #87372e; }
.question-visual-choice:focus-visible { outline: 3px solid #397a9d; outline-offset: 4px; }
.question-images-dialog { width: min(1050px, 94vw); max-width: 94vw; max-height: 88dvh; padding: 20px; border: 1px solid #ded7cd; border-radius: 18px; background: #faf8f4; color: #292522; }
.question-images-dialog[open] { display: flex; flex-direction: column; }
.question-images-dialog::backdrop { background: rgb(0 0 0 / 45%); }
.question-images-dialog header, .question-images-dialog footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; flex-shrink: 0; }
.question-images-dialog h2 { font-size: 24px; margin: 0; }
.question-images-scroll { overflow-y: auto; min-height: 0; overscroll-behavior: contain; margin: 16px 0; }
.question-images-dialog .reference-grid { max-height: none; overflow: visible; }
.question-images-error { color: #87372e; }
.ratio-picker { border: 0; padding: 0; margin: 20px 0; }
.ratio-picker legend { font-size: 22px; font-weight: 700; margin-bottom: 14px; }
.ratio-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(105px, 1fr)); gap: 12px; }
.ratio-grid button { padding: 12px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.ratio-grid button[aria-pressed="true"] { border-color: #87372e; background: #efe2d7; box-shadow: 0 0 0 2px #87372e; }
.ratio-grid button:focus-visible { outline: 3px solid #397a9d; outline-offset: 3px; }
.ratio-example { height: 80px; display: flex; align-items: center; justify-content: center; }
.ratio-example > span { display: block; border: 2px solid currentColor; background: #87372e18; }
.ratio-grid small { font-size: 14px; }
.discard-poster { color: #87372e; border-color: #b6837d; background: transparent; }
.discard-poster:hover:not(:disabled) { background: #f7e5e2; }
.poster-current-step { margin: 24px 0; }
.poster-history { border-top: 1px solid #ded7cd; padding-top: 16px; }
#poster-chat [hidden] { display: none !important; }
.poster-messages {
  max-height: 330px;
  overflow: auto;
  margin: 20px 0;
}
.poster-messages p,
.poster-copy {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
#poster-chat .bubble {
  margin: 12px 0;
  max-width: 95%;
}
#poster-chat .steps {
  flex-wrap: wrap;
}
#poster-chat pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
#poster-chat button {
  margin-top: 8px;
}
.poster-result {
  display: block;
  max-width: 100%;
  max-height: 65vh;
  object-fit: contain;
  margin: 20px auto;
}
@media (max-width: 600px) {
  .reference-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .reference-tile img {
    height: 110px;
  }
  #poster-chat .section-head {
    align-items: flex-start;
    flex-wrap: wrap;
  }
}
.nav-group { margin: 8px 0; }
.nav-group-title { padding: 8px 14px; color: #80776c; font-size: 13px; font-weight: 600; }
.nav-group-items { display: flex; flex-direction: column; gap: 4px; margin-left: 14px; padding-left: 8px; border-left: 1px solid #d5cabc; }
@media (max-width: 720px) {
  .nav-group { flex-shrink: 0; margin: 0; }
  .nav-group-title { padding: 0 10px 4px; }
  .nav-group-items { flex-direction: row; margin-left: 0; padding-left: 0; border-left: 0; }
}
.brand-avatar { display:block; width:64px; height:64px; border-radius:50%; object-fit:cover; margin:0 10px 12px; flex-shrink:0; box-shadow:0 0 0 3px #fff8; }
.is-loading::before { content: ''; display: inline-block; width: 1em; height: 1em; margin-inline-end: .65em; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; vertical-align: -.12em; animation: studio-spin .85s linear infinite; flex-shrink: 0; }
@keyframes studio-spin { to { transform: rotate(360deg); } }
.operation-loading { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); z-index: 1000; padding: 12px 20px; border: 1px solid #d8caba; border-radius: 12px; background: #fffaf4; color: #843329; box-shadow: 0 4px 18px #241a1820; pointer-events: none; }
.image-loading { background: linear-gradient(100deg, #e9e3da 25%, #faf7f2 45%, #e9e3da 65%); background-size: 220% 100%; animation: studio-shimmer 1.4s ease-in-out infinite; }
@keyframes studio-shimmer { to { background-position: -220% 0; } }
@media (prefers-reduced-motion: reduce) { .is-loading::before, .image-loading { animation: none !important; } }
/* Source crops stay uncropped so every letter can be inspected. */
.lettering-attachments { display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:16px; }
.lettering-attachments figure { margin:0; padding:12px; border:1px solid #ddd4c7; border-radius:12px; min-width:0; }
.lettering-attachments img { display:block; width:100%; max-height:220px; object-fit:contain; }
.lettering-attachments figcaption { font-weight:600; margin:8px 0; }
.lettering-choice-grid { max-height:420px; overflow-y:auto; align-items:start; padding:4px; }
.lettering-choice-grid img { height:170px; object-fit:contain; }
.question-visuals.lettering-curated { display:block; }
.lettering-curated-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin:16px 0; }
.lettering-curated-grid img { height:180px; }
.lettering-curated-grid small { display:block; padding:0 16px 16px; font-size:14px; line-height:1.6; font-weight:400; }
.lettering-curated details { border-top:1px solid #ded7cd; padding-top:16px; }
.lettering-option {min-width:0;}
.lettering-option > button {width:100%;}
.lettering-curated .lettering-help {border-top:0;padding:8px 4px;}
.lettering-help summary {font-size:14px;cursor:pointer;}
.lettering-help p {font-size:14px;line-height:1.7;margin:8px 0;}
.help-question {display:inline-flex;align-items:center;justify-content:center;border:1px solid currentColor;border-radius:50%;width:18px;height:18px;font-size:12px;}
@media(max-width:600px) { .lettering-curated-grid { grid-template-columns:1fr; } }
:root .poster-saved-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(210px,1fr)); gap: 16px; max-height: 420px; overflow: auto; margin: 16px 0; }
:root .poster-saved-grid article { border: 1px solid #ddd5c9; border-radius: 12px; padding: 16px; }
:root .poster-saved-grid img { width: 100%; height: 150px; object-fit: contain; display: block; margin-bottom: 10px; }
#poster-saved-history { padding: 16px; border: 1px solid #ddd5c9; border-radius: 12px; margin-bottom: 24px; }
.generated-results {display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,420px),1fr));gap:24px;align-items:start}
.generated-result-image {width:100%;height:420px;object-fit:contain;background:#eee9e1}
.generated-reference-grid {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.generated-reference-grid figure {margin:0;overflow-wrap:anywhere}
.generated-reference-grid img {width:100%;height:180px;object-fit:contain;background:#eee9e1}
.generated-prompt {white-space:pre-wrap;overflow-wrap:anywhere;max-height:600px;overflow:auto}
.record-filters {display:flex;flex-wrap:wrap;align-items:end;gap:16px;margin-bottom:28px;padding:20px;background:#eee8df;border-radius:12px}
.record-filters label {display:flex;flex-direction:column;gap:6px;flex:1 1 170px;min-width:0;margin:0}
.record-filters label:first-child {flex:2 1 250px}
.record-filters input,.record-filters select {width:100%;min-width:0;margin:0}
.record-filters small {flex-basis:100%}
/* Product knowledge and auditable ingestion workspace. */
.product-search { display: flex; align-items: end; gap: 1.25rem; margin-bottom: 1.5rem; }
.product-search label { flex: 1; }
.product-search input { display: block; width: 100%; }
.product-search [role="status"] { white-space: nowrap; padding-bottom: .75rem; }
.product-entry { margin-bottom: 1rem; }
.product-entry h2 { margin: .75rem 0; }
.product-facts { display: grid; grid-template-columns: repeat(auto-fit,minmax(180px,1fr)); gap: 1rem; }
.product-facts dt { color: #887e72; font-size: .85rem; }
.product-facts dd { margin: .25rem 0 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.product-local-photos { display: flex; gap: 1rem; flex-wrap: wrap; }
.product-local-photos img { width: 160px; height: 180px; object-fit: contain; }
.product-wiki { align-items: start; }
.product-local-photos > a { display: flex; flex-direction: column; max-width: 240px; overflow-wrap: anywhere; }
.product-local-photos small { max-width: 240px; }
.product-photo-variant { padding: 16px 0; border-bottom: 1px solid var(--wiki-border); }
.product-photo-candidates { padding: 16px; margin: 24px 0; background: #eee4d8; border-radius: 8px; }
.product-wiki > .doclist { max-height: 76vh; overflow-y: auto; padding-right: 4px; }
.product-wiki-article { min-width: 0; min-height: 480px; }
.product-wiki-article .product-local-photos img { width: 240px; height: 260px; max-width: 100%; }
.product-wiki-article .product-facts { border-top: 1px solid var(--wiki-border); padding-top: 20px; }
.product-wiki-toolbar { margin-top: 24px; }
@media (max-width: 760px) {
  .product-wiki { grid-template-columns: minmax(0, 1fr); }
  .product-wiki > .doclist { max-height: 280px; }
  .product-wiki-toolbar { flex-wrap: wrap; }
  .product-wiki-toolbar input, .product-wiki-toolbar select { min-width: 0; width: 100%; flex-basis: 100%; }
}
.product-preview-table { overflow-x: auto; max-height: 480px; }
.product-preview-table table { width: 100%; border-collapse: collapse; }
.product-preview-table td, .product-preview-table th { padding: .7rem; border-bottom: 1px solid #e2dcd3; text-align: left; }
#product-ingestion-form input { width: 100%; margin-bottom: 1rem; }
@media(max-width: 650px) { .product-search { display: block; } }
.product-article-hero { display:grid; grid-template-columns:minmax(0,1fr) minmax(220px,320px); gap:28px; align-items:start; }
.product-article-hero > div { min-width:0; }
.product-article-hero h1 { font-size:32px; overflow-wrap:anywhere; }
.product-carousel { min-width:0; }
.product-carousel-frame { position:relative; background:#f5f2ed; border-radius:12px; overflow:hidden; }
.product-carousel-frame a { display:block; }
.product-carousel-frame a[hidden] { display:none; }
.product-carousel-frame img { display:block; width:100%; height:320px; object-fit:contain; }
.product-carousel-frame button { position:absolute; top:50%; transform:translateY(-50%); width:40px; height:44px; padding:0; background:#fff; font-size:28px; }
.product-photo-prev { left:8px; }
.product-photo-next { right:8px; }
.product-photo-dots { display:flex; justify-content:center; flex-wrap:wrap; gap:2px; margin-top:8px; }
.product-photo-dots button { display:grid; place-items:center; width:28px; height:28px; padding:0; border:0; background:transparent; }
.product-photo-dots button::after { content:""; width:8px; height:8px; border-radius:50%; background:#c9c0b5; }
.product-photo-dots button[aria-current="true"]::after { background:#863b32; }
.product-photo-count { text-align:center; font-size:13px; margin:0; }
@media(max-width:1000px) { .product-article-hero { grid-template-columns:minmax(0,1fr); } .product-carousel { width:100%; max-width:360px; } }
.question-visuals.poster-subject-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.poster-subject-grid .question-visual-choice img { height: 280px; object-fit: contain; }
@media (max-width: 800px) { .question-visuals.poster-subject-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.pose-vault-layout {display:grid;grid-template-columns:260px minmax(0,1fr);gap:24px;align-items:start}
.pose-vault-list {max-height:80vh;overflow:auto;display:grid;gap:8px}
.pose-vault-list button {text-align:left;width:100%}
.pose-vault-list small {display:block;color:var(--muted);margin-top:6px}
.pose-vault-list button[aria-pressed=true] {background:#ede3d6;border-color:#a9866e}
.pose-vault-reader {min-width:0}
.pose-comparison {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.pose-comparison figure {margin:0;min-width:0}
.pose-comparison figure:only-child {grid-column:1 / -1}
.pose-comparison figcaption {margin:10px 0;font-weight:600}
.pose-comparison img {width:100%;height:430px;object-fit:contain;background:#eee9e1;border-radius:12px}
.pose-empty {height:430px;display:grid;place-items:center;text-align:center;padding:20px;background:#eee9e1;border-radius:12px;color:#82786d}
.pose-inputs {display:flex;gap:10px;flex-wrap:wrap}
.pose-inputs figure {margin:0;max-width:130px}
.pose-inputs img {width:100%;height:140px;object-fit:contain}
.pose-vault-reader pre {white-space:pre-wrap;overflow-wrap:anywhere}
@media(max-width:800px){.pose-vault-layout{grid-template-columns:1fr}.pose-vault-list{max-height:220px}.pose-comparison img,.pose-empty{height:260px}}
.video-step-nav{display:flex;flex-wrap:wrap;gap:8px;margin:20px 0}.video-step-nav [aria-current=step]{background:#eee3d6;border-color:#843329}.video-ref-grid,.video-story-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.video-ref-grid figure{margin:0}.video-ref-grid img,.video-pose-preview{width:100%;height:180px;object-fit:contain;background:#eee9e0}.video-ref-grid figcaption{overflow-wrap:anywhere;font-size:14px}#video-chat textarea{min-height:100px}#video-story-json{min-height:360px;font-family:monospace}#video-chat pre{white-space:pre-wrap;overflow-wrap:anywhere;max-height:500px;overflow:auto}#video-chat label{display:block;margin:16px 0}#video-chat input[type=checkbox]{width:auto}@media(max-width:650px){.video-ref-grid,.video-story-grid{grid-template-columns:1fr}}
#video-product-picker .actions{display:none}
.video-progress{padding:12px 16px;background:#eee9e1;border-radius:10px;color:#63584e}
#video-duration{width:100%;padding:0;accent-color:#87372e;cursor:pointer;min-height:36px}
.video-duration-ticks{display:flex;justify-content:space-between;gap:8px;color:#80786d;font-size:14px;margin-bottom:28px}
[data-video-ratio="9:16"] .ratio-example>span{width:42.75px;height:76px}
[data-video-ratio="16:9"] .ratio-example>span{width:76px;height:42.75px}
[data-video-ratio="1:1"] .ratio-example>span{width:76px;height:76px}
[data-video-ratio="3:4"] .ratio-example>span{width:57px;height:76px}
[data-video-ratio="4:3"] .ratio-example>span{width:76px;height:57px}
[data-video-ratio="21:9"] .ratio-example>span{width:76px;height:32.57px}
.video-scenes{border:0;padding:0;margin:20px 0}.video-scenes legend{font-size:22px;font-weight:700;margin-bottom:16px}
.video-scene-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}
.video-scene-card{position:relative;aspect-ratio:1;min-width:0;padding:0;overflow:hidden;border:2px solid #ded7cd;border-radius:12px;display:block;background:transparent}
.video-scene-card img{width:100%;height:100%;object-fit:cover;display:block}
.video-scene-card>span:not(.video-scene-plus){position:absolute;bottom:0;left:0;right:0;padding:10px;background:#fffef1ed;color:#302b27;font-weight:600;overflow-wrap:anywhere}
.video-scenes [aria-pressed=true]{border-color:#87372e;box-shadow:0 0 0 2px #87372e}
.video-scene-card:focus-visible{outline:3px solid #397a9d;outline-offset:3px}
.video-scene-upload,.video-scene-upload:hover{background:transparent;border:2px dashed #999;color:#777}
.video-scene-plus{display:block;font-size:54px;font-weight:300;line-height:1}
.video-scene-upload>.video-scene-upload-label{opacity:0;background:transparent!important;color:#777!important;transition:opacity .15s}
.video-scene-upload:hover>.video-scene-upload-label,.video-scene-upload:focus-visible>.video-scene-upload-label{opacity:1}
@media(hover:none){.video-scene-upload>.video-scene-upload-label{opacity:1}}
@media(max-width:650px){.video-scene-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}}
.video-loading { display:flex; align-items:center; gap:14px; padding:18px; border:1px solid #ded7cd; border-radius:12px; background:#efe6d8; color:#87372e; }
.video-loading small { display:block; margin-top:6px; color:#655d54; }
.video-loading-spinner { flex:0 0 auto; width:26px; height:26px; border:3px solid #d8c4b8; border-top-color:#87372e; border-radius:50%; animation:video-loading-spin .85s linear infinite; }
@keyframes video-loading-spin { to { transform:rotate(360deg); } }
.video-generation-activity { display:flex; align-items:center; gap:14px; min-height:84px; margin:16px 0; padding:16px; background:#f4ece3; border-radius:12px; }
.video-render-choices { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:18px; margin:24px 0; }
.video-render-choices button { min-height:110px; padding:22px; font-size:20px; font-weight:700; border:2px solid #87372e; text-align:left; }
.video-render-choices button span { display:block; font-size:14px; font-weight:400; margin-top:10px; }
.video-render-choices button:disabled { opacity:.5; cursor:not-allowed; }
.video-music-summary { padding:16px; background:#eee8df; border-radius:12px; }
@media(max-width:700px) { .video-render-choices { grid-template-columns:1fr; } }
.video-generation-activity small { display:block; margin-top:6px; color:#766c62; }
.video-generation-activity.is-queued { background:#f1efeb; }
.video-generation-activity.is-queued .video-loading-spinner { border-color:#ddd8d0; border-top-color:#93897e; animation-duration:2s; }
@media (prefers-reduced-motion:reduce) { .video-loading-spinner { animation:none; } }
.video-result {display:block;width:100%;max-height:65vh;background:#111;border-radius:12px;}
.panel > .video-loading-spinner {display:inline-block;}
.video-scenes:has([data-scene="AI 決定"][aria-pressed="true"]) .video-scene-card img {filter:grayscale(1);opacity:.4;}
.video-season-grid {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;}
.video-seasons [data-season] {cursor:pointer;}
.video-seasons [data-season]:hover {border-color:#a9866e;}
.video-seasons [data-season][aria-pressed=true] {border-color:#87372e;box-shadow:0 0 0 2px #87372e;background:#efe2d7;}
.video-seasons [data-season][aria-pressed=true]::after {content:'✓ 已選';display:inline-block;background:#87372e;color:#fff;padding:4px 9px;border-radius:6px;font-size:14px;font-weight:600;margin-left:10px;}
.video-seasons .video-scene-card[aria-pressed=true]::after {position:absolute;top:10px;right:10px;margin:0;pointer-events:none;}
.video-seasons [data-season]:focus-visible {outline:3px solid #397a9d;outline-offset:5px;}
.video-seasons:has([data-season="AI 決定"][aria-pressed="true"]) img {filter:grayscale(1);opacity:.4;}
@media(max-width:650px){.video-season-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;}}
.video-revision-modes {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-bottom:18px;}
.video-revision-modes button {text-align:left;white-space:normal;}
.video-revision-modes span {display:block;font-size:.9em;margin-top:8px;}
.video-revision-modes [aria-pressed=true] {border-color:#87372e;background:#efe6d8;}
#video-revision:disabled {background:#e8e5e0;color:#77716b;cursor:not-allowed;opacity:1;}
@media(max-width:500px){.video-revision-modes{grid-template-columns:1fr;}}
/* Final video review: two readable editors, one confirmation action. */
.video-text-editor { margin-block: 1.8rem; }
.video-text-editor > label { font-size: 1.2rem; font-weight: 700; }
#video-chat .video-text-editor textarea { min-height: 26rem; width: 100%; line-height: 1.8; resize: vertical; white-space: pre-wrap; }
#video-review-assets audio { max-width: 100%; }
.video-confirm { margin-top: 2rem; }
.video-frame-card textarea{width:100%;min-height:240px!important}.video-frame-card>button{margin:12px 0}.video-frame-versions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.video-frame-versions figure{margin:12px 0;padding:12px;border:1px solid #e5ded5;border-radius:12px}.video-frame-versions figcaption{overflow-wrap:anywhere}.video-frame-versions button{width:100%;margin-top:8px}@media(max-width:650px){.video-frame-versions{grid-template-columns:1fr}}
#production-history{margin-top:28px}#production-history summary{cursor:pointer}#production-history pre{white-space:pre-wrap;overflow-wrap:anywhere;max-height:480px;overflow:auto}.history-job{padding:20px 0;border-top:1px solid #e5ded5}.history-job>img,.history-job>video{max-width:100%;max-height:360px}.history-references{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:12px}.history-references figure{margin:0;overflow-wrap:anywhere}.history-references img{width:100%;height:160px;object-fit:contain}.history-references audio{max-width:100%}.video-credit-total{font-size:32px;font-weight:700}#video-film-quote{border:2px solid #87372e}#video-film-quote button{margin:8px 12px 8px 0}
.library-create,.library-summary,.library-tabs,.library-card-actions,.library-pagination{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.library-create button{white-space:nowrap}.library-summary button{padding:8px 12px;font-size:14px}.library-notice{display:flex;gap:16px;align-items:center;justify-content:space-between;padding:12px 16px;background:#eee7dc;border-radius:10px;font-size:14px}.library-notice button{padding:6px 12px;white-space:nowrap}
.library-tools{background:#fffdfa;border:1px solid #e5ded5;border-radius:14px;padding:20px}.library-search{display:block;margin:0 0 16px}.library-search input{width:100%;margin-top:8px}.library-tabs button{padding:9px 16px}.library-tabs [aria-pressed=true]{background:#87372e;border-color:#87372e;color:#fff}.library-filters{display:flex;align-items:end;flex-wrap:wrap;gap:12px;margin-top:16px}.library-filters label{flex:1;min-width:135px;margin:0;font-size:13px}.library-filters select,.library-filters input{display:block;width:100%;margin-top:5px;padding:10px}.library-filters>button{padding:10px}
.library-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}.library-card{min-width:0;background:#fffdfa;border:1px solid #e5ded5;border-radius:14px;overflow:hidden}.library-preview{border:0;border-radius:0;padding:0;display:grid;position:relative;width:100%;height:220px;background:#eae4dc;overflow:hidden}.library-preview img,.library-preview video{width:100%;height:220px;object-fit:contain;min-width:0}.library-preview.is-mosaic{grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:110px;gap:3px}.library-preview.is-mosaic img{height:110px;object-fit:cover}.library-preview:hover{filter:brightness(.97)}.library-play{position:absolute;bottom:12px;left:12px;background:#241e1bdd;color:#fff;border-radius:20px;padding:7px 14px}.library-draft{display:flex;flex-direction:column;justify-content:center;text-align:left;padding:24px;gap:14px}.library-draft span{display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;font-size:15px;line-height:1.7}
.library-card-body{padding:18px}.library-card-body h3{font-size:19px;line-height:1.5;margin:12px 0 6px;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.library-card-body p{margin:6px 0;font-size:14px}.library-card-body small{font-size:12px;color:#756c63}.library-status{display:inline-block;border-radius:20px;background:#eee7dc;color:#6b5946;padding:4px 9px;font-size:12px}.library-status.completed,.library-status.image,.library-status.boards{background:#e4edde;color:#405d35}.library-status.attention{background:#f6dfd9;color:#922f23}.library-status.running{background:#e2eaf4;color:#305f88}.library-card-actions{margin-top:16px}.library-card-actions button,.library-link{font-size:14px}.library-card-actions button{padding:9px 12px}.library-link{color:#87372e;text-decoration:underline;text-underline-offset:3px}.library-pagination{justify-content:center;margin-top:24px}.library-empty{padding:36px;text-align:center;grid-column:1/-1;color:#756c63}
.library-list{grid-template-columns:1fr}.library-list .library-card{display:grid;grid-template-columns:210px minmax(0,1fr)}.library-list .library-preview,.library-list .library-preview>img,.library-list .library-preview>video{height:180px}.library-list .library-preview.is-mosaic{grid-auto-rows:90px}.library-list .library-preview.is-mosaic img{height:90px}
.library-detail{background:#fffdfa;border:1px solid #e5ded5;border-radius:16px;padding:26px;scroll-margin-top:20px}.library-detail>label{display:block;max-width:460px;margin:20px 0}.library-detail select{width:100%;margin-top:8px}.library-detail .library-tabs{border-bottom:1px solid #e5ded5;padding-bottom:14px;margin-bottom:22px}.library-player{display:block;max-width:100%;width:100%;max-height:560px;background:#171411;border-radius:12px}.library-output-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-top:22px}.library-output-grid figure{margin:0;min-width:0}.library-output-grid button{display:block;padding:0;width:100%;overflow:hidden;border-radius:10px;background:#eee7dc}.library-output-grid img{display:block;width:100%;height:230px;object-fit:contain}.library-output-grid figcaption{font-size:13px;margin:8px 0;overflow-wrap:anywhere}.library-lightbox{width:min(1000px,94vw);max-height:94vh;padding:20px;border:0;border-radius:14px}.library-lightbox::backdrop{background:#000b}.library-lightbox>button{display:block;margin-left:auto}.library-lightbox>img{display:block;max-width:100%;max-height:72vh;margin:auto}.library-lightbox>div{display:flex;justify-content:center;align-items:center;gap:20px;margin-top:14px}
@media(max-width:1100px){.library-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.library-list{grid-template-columns:1fr}.library-output-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:650px){.library-grid{grid-template-columns:1fr}.library-create{margin-top:12px}.library-filters label{min-width:120px}.library-list .library-card{grid-template-columns:110px minmax(0,1fr)}.library-card-body{padding:14px}.library-list .library-card-actions{flex-direction:column;align-items:start}.library-detail{padding:16px}.library-output-grid{grid-template-columns:1fr}.library-tools{padding:14px}#production-history .section-head{flex-wrap:wrap;gap:12px}.library-notice{align-items:start}.library-detail .section-head button{font-size:13px}}
.social-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 20px; margin: 24px 0; }
.social-two { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 24px; }
#social-studio { max-width: 1400px; }
#social-studio .panel { margin-bottom: 22px; min-width: 0; overflow-wrap: anywhere; }
#social-studio input, #social-studio select, #social-studio textarea { width: 100%; box-sizing: border-box; }
#social-studio input[type=checkbox] { width: auto; flex-shrink: 0; }
#social-studio label { display: block; margin: 12px 0; }
#social-studio .check { display: flex; gap: 10px; align-items: baseline; }
#social-studio button { margin: 8px 8px 8px 0; }
#social-studio button:disabled { opacity: .5; cursor: not-allowed; }
#social-studio a { text-decoration: underline; text-underline-offset: 4px; }
#social-studio p { line-height: 1.7; }
#social-studio [hidden] { display: none; }
#social-studio progress { width: 100%; accent-color: #8d342d; margin: 12px 0 24px; }
#social-studio img, #social-studio video { display: block; max-width: 100%; max-height: 320px; object-fit: contain; margin: 16px auto; }
.social-notice { padding: 16px 20px; border-left: 4px solid #8d342d; background: #f1e8dc; margin: 16px 0; line-height: 1.6; }
.social-guide { border: 2px solid #8d342d; }
.social-guide li { padding: 8px 0; line-height: 1.7; }
.social-platform { background: #efe6da; border-radius: 14px; width: 48px; height: 48px; display: grid; place-items: center; font-weight: 700; }
.social-source-list { max-height: 250px; overflow: auto; padding: 12px; border: 1px solid #e4ddd3; }
.social-history { padding: 20px 0; border-top: 1px solid #e4ddd3; }
.social-copy { white-space: pre-wrap; }
.social-confirm { border: 2px solid #8d342d; }
.social-tabs [aria-pressed=true] { background: #8d342d; color: white; }
.social-kpis { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 16px; margin-top: 22px; }
.social-kpis div { background: #f5f1eb; padding: 20px; border-radius: 12px; }
.social-kpis strong { display: block; font-size: 30px; margin-top: 10px; }
#social-studio dl > div { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px solid #eee8df; padding: 8px 0; }
#social-status:not(:empty) { padding: 16px; background: #eee7db; position: sticky; top: 0; z-index: 2; border-radius: 10px; }
@media(max-width:1000px) { .social-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media(max-width:650px) { .social-grid,.social-two { grid-template-columns: 1fr; } .social-kpis { grid-template-columns: repeat(2,minmax(0,1fr)); } #social-studio .panel { padding: 20px; } }
.sd-dashboard{display:grid;gap:24px;min-width:0}.sd-dashboard .panel{margin:0;min-width:0}.sd-filters{display:flex;flex-wrap:wrap;justify-content:space-between;gap:16px;margin-top:20px}.sd-switch{display:flex;flex-wrap:wrap;gap:4px;background:#eee8df;padding:5px;border-radius:24px}.sd-switch button{padding:9px 18px;border:0;border-radius:20px;background:transparent;min-width:52px}.sd-switch button[aria-pressed=true]{background:#88372f;color:white}.sd-platforms{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;margin-top:22px}.sd-platform{border:1px solid #e6dfd6;border-top:4px solid;border-radius:14px;padding:22px}.sd-platform h3{margin-top:0}.sd-platform dl>div{display:flex;justify-content:space-between;gap:12px;padding:7px 0}.sd-platform dd{margin:0;text-align:right;font-weight:600}.sd-platform small{display:block;font-weight:400;font-size:12px;color:#75695e}.sd-border-instagram{border-color:#b73584}.sd-border-facebook{border-color:#2979ce}.sd-border-threads{border-color:#ad791d}.sd-instagram{color:#b73584}.sd-facebook{color:#2979ce}.sd-threads{color:#ad791d}.sd-micro{font-size:13px;line-height:1.8;color:#75695e}.sd-chart{display:block;width:100%;min-width:0;height:auto;margin:18px 0}.sd-chart text{font-size:12px;fill:#75695e}.sd-chart circle:focus{stroke:#211d1a;stroke-width:3px;outline:none}.sd-legend{display:flex;gap:20px;flex-wrap:wrap}.sd-empty{padding:40px 20px;text-align:center;background:#f5f1eb;border:1px dashed #d8ccbf;border-radius:12px;color:#75695e;margin:18px 0}.sd-posts{list-style:none;padding:0;display:grid;gap:14px}.sd-post{display:grid;grid-template-columns:28px 90px minmax(0,1fr);gap:20px;border:1px solid #e6dfd6;border-left:4px solid;border-radius:12px;padding:20px}.sd-post.sd-border-instagram{border-left-color:#b73584}.sd-post.sd-border-facebook{border-left-color:#2979ce}.sd-post.sd-border-threads{border-left-color:#ad791d}.sd-post p{overflow-wrap:anywhere}.sd-rank{font-size:24px}.sd-thumb{height:105px;background:#eee8df;border-radius:8px;overflow:hidden;display:grid;place-items:center}.sd-thumb img{width:100%;height:100%;object-fit:cover}.sd-no-image{font-size:12px;text-align:center;padding:8px}.sd-table{overflow:auto;max-height:360px}.sd-table table{width:100%;border-collapse:collapse}.sd-table td,.sd-table th{text-align:left;padding:12px;border-bottom:1px solid #e6dfd6;white-space:nowrap}.sd-dashboard .section-head{gap:16px;flex-wrap:wrap}.sd-dashboard h2{font-size:24px}.sd-dashboard details{margin-top:14px}
@media(max-width:1050px){.sd-platforms{grid-template-columns:1fr}.sd-post{grid-template-columns:24px 70px minmax(0,1fr);gap:10px}}
@media(max-width:600px){.sd-post{grid-template-columns:24px minmax(0,1fr)}.sd-thumb{grid-column:2;width:90px;height:100px}.sd-post>div:last-child{grid-column:1/-1}.sd-switch button{padding:8px 12px}.sd-dashboard .panel{padding:18px}.sd-dashboard h2{font-size:21px}}
.editor-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px}.editor-media{min-width:0}.editor-media>img,.editor-media>video{display:block;width:100%;height:240px;object-fit:contain;background:#eee8df;border-radius:10px}.editor-eligibility{margin:16px 0;font-size:14px}.editor-media p{overflow-wrap:anywhere}#ai-editor .library-tabs{margin-bottom:22px}#editor-settings fieldset{margin:20px 0}#editor-settings fieldset .check{display:inline-flex;margin-right:18px}#editor-settings .social-source-list .check{display:flex}#ai-editor .social-kpis{margin:20px 0}#ai-editor input[type=checkbox]{width:auto}#ai-editor fieldset{min-width:0}#ai-editor .social-copy{white-space:pre-wrap}.editor-eligibility input{width:auto}
@media(max-width:720px){.editor-grid{grid-template-columns:1fr}}
.publication-record { display: grid; grid-template-columns: minmax(250px, 34%) minmax(0, 1fr); gap: 0; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: var(--white); }
#publication-library .library-tools { display: grid; grid-template-columns: 1fr 1fr 2fr; gap: 16px; padding: 16px; }
#publication-library .library-tools label { min-width: 0; }
@media (max-width: 700px) { #publication-library .library-tools { grid-template-columns: 1fr; } }
.social-connection-compact { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 18px 24px; }
.publication-record > div { min-width: 0; }
.publication-records { display: grid; gap: 24px; margin-top: 20px; }
#social-studio #publication-library { padding: 24px; }
#publication-library > .section-head { margin: 0; }
#publication-library > .section-head h2 { margin: 0; }
#publication-library .library-tools { margin: 12px 0; padding: 10px 0; border: 0; border-radius: 0; }
#publication-library .library-tools label { margin: 0; }
.publication-visual { position: relative; background: #eae4db; display: flex; flex-direction: column; justify-content: center; min-height: 360px; }
.publication-visual a { display: block; }
#social-studio .publication-visual img, #social-studio .publication-visual video { display: block; width: 100%; height: 420px; max-height: none; object-fit: contain; border-radius: 0; }
.publication-format { position: absolute; top: 14px; left: 14px; background: #302a26dc; color: white; padding: 5px 12px; border-radius: 20px; z-index: 1; font-size: 12px; }
.publication-visual-hint { text-align: center; padding: 12px; color: #61554b; font-size: 12px; }
.publication-content { padding: 24px; }
.publication-meta { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13px; }
.publication-status { background: #f3e6d7; padding: 6px 10px; border-radius: 20px; font-weight: 600; }
.publication-status[data-state=published] { background: #e5efe3; color: #355d3c; }
.publication-status[data-state=failed], .publication-status[data-state=unknown] { background: #f6e0dc; color: #85332d; }
#publication-library .publication-content h3 { margin: 16px 0 4px; font-size: 23px; }
.publication-origin { font-size: 12px; color: var(--muted); margin: 0 0 14px; }
.publication-dates { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 14px 0; }
.publication-dates dt, .publication-caption > span { color: var(--muted); font-size: 12px; }
.publication-dates > div { display: block; border: 0; padding: 0; }
.publication-dates dd { margin: 4px 0 0; font-size: 13px; }
.publication-caption { border-top: 1px solid var(--line); padding-top: 14px; }
.publication-caption p { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.65; max-height: 180px; overflow: auto; margin: 6px 0 14px; }
.publication-metrics { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 6px; padding: 12px; border-radius: 10px; background: #f6f3ee; }
.publication-metrics div { display: flex; flex-direction: column; gap: 4px; }
.publication-metrics strong { font-size: 22px; }
.publication-metrics span { font-size: 12px; color: var(--muted); }
.publication-performance > p { font-size: 11px; color: var(--muted); margin: 8px 0; }
.publication-audit { font-size: 12px; margin-top: 12px; overflow-wrap: anywhere; }
#publication-library .social-kpis { margin: 14px 0; gap: 10px; }
#publication-library .social-kpis div { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; }
#publication-library .social-kpis strong { margin: 0; font-size: 22px; }
#publication-library > .actions { margin: 10px 0; }
#publication-library > .section-head p { margin: 6px 0; }
#publication-composer > summary { cursor: pointer; font-weight: 600; }
#publication-composer #social-publish { padding: 20px 0 0; margin: 0; border: 0; }
@media (max-width: 850px) { .publication-record { grid-template-columns: 1fr; } #social-studio .publication-visual img, #social-studio .publication-visual video { height: 360px; } .publication-content { padding: 18px; } }
@media (max-width: 500px) { .publication-dates { grid-template-columns: 1fr; } #publication-library .social-kpis { grid-template-columns: 1fr 1fr; } }
