@font-face {
  font-family: Mochi;
  src: url("/fonts/mochi.ttf");
}
@font-face {
  font-family: Qahiri;
  src: url("/fonts/qahiri.ttf");
}
@font-face {
  font-family: Rounded;
  src: url("/fonts/rounded.ttf");
  font-weight: 800;
}
@font-face {
  font-family: Noto;
  src: url("/fonts/noto.ttf");
  font-weight: 100 900;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: #f8f7f2;
  color: #22251f;
  font-family:
    system-ui,
    -apple-system,
    "Noto",
    sans-serif;
  font-size: 14px;
}
header {
  height: 82px;
  border-bottom: 1px solid #dddcd5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5vw;
}
.brand {
  font-size: 32px;
  font-weight: 900;
  letter-spacing: -2px;
  color: inherit;
  text-decoration: none;
}
.brand span {
  font-size: 12px;
  letter-spacing: 2px;
  margin-left: 16px;
}
.badge {
  border: 1px solid #d0d3c8;
  border-radius: 30px;
  padding: 8px 14px;
  font-size: 11px;
}
main {
  max-width: 1500px;
  margin: auto;
  padding: 38px 5vw;
}
.eyebrow {
  color: #627653;
  letter-spacing: 3px;
  font-size: 11px;
  font-weight: 700;
}
h1 {
  font-size: clamp(24px, 3vw, 36px);
  letter-spacing: -1px;
  margin: 12px 0;
}
h2 {
  font-size: 17px;
}
h3 {
  font-size: 14px;
}
.intro > p:last-child {
  color: #71766b;
}
nav {
  display: flex;
  gap: 28px;
  margin-top: 32px;
  border-bottom: 1px solid #d9dbd3;
}
button {
  font: inherit;
  cursor: pointer;
  border: 1px solid #cbd0c4;
  background: #fff;
  color: #24351b;
  border-radius: 7px;
  padding: 11px 15px;
}
button:hover {
  background: #e9efdf;
}
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
nav button {
  background: none;
  border: 0;
  border-radius: 0;
  padding: 16px 0;
  color: #767d6c;
}
nav button.active {
  color: #2e4920;
  border-bottom: 3px solid #436134;
  font-weight: 700;
}
.workspace {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 36px;
}
form {
  background: #fff;
  border: 1px solid #e0e2d9;
  border-radius: 12px;
  padding: 24px;
}
label {
  display: block;
  margin: 17px 0 6px;
  font-size: 12px;
  font-weight: 650;
}
input,
select {
  width: 100%;
  padding: 12px;
  border: 1px solid #ccd1c4;
  border-radius: 6px;
  background: #fff;
  color: #262c21;
  font: inherit;
  margin-top: 7px;
  min-height: 44px;
}
input:focus,
select:focus,
button:focus-visible {
  outline: 2px solid #658848;
  outline-offset: 2px;
}
.pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  min-width: 0;
}
.pair input {
  min-width: 0;
}
.hint {
  font-size: 11px;
  line-height: 1.7;
  color: #767b70;
}
.section-head {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 14px;
}
.section-head:first-child {
  margin-top: 0;
}
.section-head span {
  font-size: 10px;
  background: #eaf0df;
  border-radius: 50%;
  padding: 8px;
  color: #58763c;
}
.section-head h2 {
  margin: 0;
}
.preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.preview-head span {
  font-size: 10px;
  color: #7b8173;
  letter-spacing: 1px;
}
.canvas-wrap {
  background: #e7e9df;
  border: 1px solid #d9ddd0;
  border-radius: 10px;
  padding: 20px;
  margin-top: 10px;
}
canvas {
  width: 100%;
  height: auto;
  display: block;
}
aside {
  position: sticky;
  top: 20px;
  align-self: start;
}
.draft {
  font-size: 11px;
  color: #8c5939;
  background: #f3eadd;
  padding: 11px;
  border-radius: 5px;
}
#validation {
  font-size: 12px;
  line-height: 1.8;
}
#validation ul {
  padding-left: 20px;
}
.error {
  color: #96453d;
}
.warning {
  color: #80652d;
}
.check {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  line-height: 1.5;
}
.check input {
  width: 17px;
  min-height: 17px;
  margin: 0;
  flex-shrink: 0;
}
.primary {
  background: #2e4723;
  color: #fff;
  border-color: #2e4723;
}
.primary:hover {
  background: #446337;
}
.actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 22px;
}
#export {
  width: 100%;
  margin-top: 15px;
}
summary {
  font-size: 12px;
  cursor: pointer;
  padding: 12px 0;
  color: #567244;
}
#status {
  min-height: 20px;
  font-size: 13px;
}
.cards {
  display: grid;
  gap: 12px;
}
.card {
  padding: 20px;
  background: #fff;
  border: 1px solid #dce0d3;
  border-radius: 9px;
}
.card p {
  white-space: pre-line;
}
.card button {
  margin-right: 8px;
}
footer {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  letter-spacing: 1px;
  padding: 30px 5vw;
  color: #858b7d;
  border-top: 1px solid #ddd;
}
#person-preview {
  background: #eee;
  margin-top: 15px;
  border: 1px solid #ccc;
}
[hidden] {
  display: none !important;
}
@media (max-width: 900px) {
  .workspace {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  aside {
    position: static;
  }
  header {
    height: 66px;
  }
  .badge {
    display: none;
  }
  main {
    padding: 24px 5vw;
  }
  .canvas-wrap {
    padding: 8px;
  }
  nav {
    gap: 18px;
  }
  nav button {
    font-size: 12px;
  }
  .brand span {
    font-size: 10px;
  }
  footer span {
    display: none;
  }
}
.mode-label {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  margin: 0;
}
.mode-label select {
  width: auto;
  margin: 0;
}
.rule-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.rule-grid label {
  min-width: 0;
}
.rule-grid input {
  min-width: 0;
}
.asset-thumb {
  width: 120px;
  height: 80px;
  object-fit: contain;
  background: #ddd;
}
#template-list {
  margin: 22px 0;
}
#definition-form {
  margin: 24px 0;
}
textarea {
  width: 100%;
  min-height: 70px;
  display: block;
  padding: 12px;
  border: 1px solid #ccd1c4;
  border-radius: 6px;
  font: inherit;
}
fieldset {
  border: 1px solid #ddd;
  border-radius: 6px;
  margin: 14px 0;
  padding: 14px;
}
@media (max-width: 600px) {
  header {
    height: auto;
    min-height: 90px;
    flex-wrap: wrap;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .mode-label {
    font-size: 9px;
  }
  .mode-label select {
    font-size: 10px;
    padding: 6px;
    min-height: 32px;
  }
  nav {
    gap: 12px;
    flex-wrap: wrap;
  }
  .rule-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
/* Quiet monochrome workshop: the banner artwork retains its own palette. */
:root { --canvas:#f5f5f5; --paper:#fff; --ink:#0a0a0a; --muted:#737373; --line:#e5e5e5; --error:#e7000b; }
body { background:var(--canvas); color:var(--ink); font-family:Geist,Inter,-apple-system,BlinkMacSystemFont,"Noto",sans-serif; font-size:14px; line-height:1.43; }
header { height:72px; padding:0 max(24px,calc((100vw - 1232px)/2)); background:#fafafa; border-color:var(--line); }
.brand { font-size:28px; font-weight:600; letter-spacing:-.05em; }
.brand span { font-size:12px; letter-spacing:.05em; font-weight:500; }
main { max-width:1280px; padding:24px; }
.intro { margin:0 0 20px; }
h1 { font-size:30px; font-weight:600; letter-spacing:-.025em; margin:8px 0; }
h2 { font-size:18px; font-weight:600; } h3 { font-size:16px; font-weight:600; }
.eyebrow,.intro>p:last-child { color:var(--muted); letter-spacing:0; font-size:14px; }
nav { margin:0 0 12px; padding:6px; gap:8px; background:#fafafa; border:1px solid var(--line); border-radius:24px; width:fit-content; }
button,nav button { border-radius:18px; padding:9px 16px; font-size:14px; font-weight:500; color:var(--ink); border:1px solid var(--line); background:var(--paper); }
button:hover,nav button:hover { background:#f5f5f5; }
nav button { border-color:transparent; background:transparent; }
nav button.active { background:#171717; color:#fafafa; border-color:#171717; font-weight:500; }
.workspace { grid-template-columns:360px minmax(0,1fr); gap:20px; align-items:start; }
form,aside,.card { background:var(--paper); border:1px solid var(--line); border-radius:24px; padding:20px; box-shadow:0 0 0 1px rgba(23,23,23,.05),0 1px 3px rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1); }
label { font-size:14px; font-weight:500; margin:14px 0 6px; }
input,select,textarea { border:1px solid transparent; border-radius:18px; padding:9px 12px; margin-top:6px; min-height:38px; background:#f5f5f5; color:var(--ink); font-size:14px; font-weight:400; }
input::placeholder,textarea::placeholder { color:var(--muted); }
input:focus,select:focus,textarea:focus,button:focus-visible { outline:1px solid var(--line); outline-offset:0; border-color:#737373; }
.hint,.check,summary,#status,.preview-head span,.draft,#validation { font-size:14px; color:var(--muted); line-height:1.5; letter-spacing:0; }
.section-head { margin:20px 0 8px; gap:8px; }
.section-head span { color:#171717; background:#f5f5f5; border-radius:18px; padding:3px 8px; font-size:12px; }
.canvas-wrap { background:#f5f5f5; border:1px solid var(--line); border-radius:24px; padding:12px; margin-top:12px; }
.draft { background:#fafafa; border-radius:18px; padding:8px 12px; }
.primary { background:#171717; color:#fafafa; border-color:#171717; }
.primary:hover { background:#333; }
.error,#input-attention { color:var(--error); } .warning { color:var(--muted); }
#input-attention:empty { display:none; } #input-attention { margin:10px 0; font-size:14px; }
summary { padding:10px 0; }
footer { color:var(--muted); font-size:12px; letter-spacing:.05em; border-color:var(--line); padding:20px max(24px,calc((100vw - 1232px)/2)); }
fieldset,#person-preview { border-color:var(--line); border-radius:24px; }
@media(max-width:900px) { .workspace { grid-template-columns:1fr; } aside { position:static; } header { padding:12px 24px; height:auto; gap:12px; flex-wrap:wrap; } main { padding:20px; } nav { flex-wrap:wrap; width:100%; } nav button,.mode-label,.mode-label select { font-size:14px; } .brand span { font-size:12px; } }

input[type=checkbox] { accent-color:#171717; }
