:root {
  font-family: Geist, Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #16181d;
  background: #f7f7f8;
  --paper: #fff;
  --border: #dedee3;
  --muted: #626571;
  --action: #131827;
  --success: #15803d;
  --rail-width: 246px;
}
* { box-sizing: border-box; }
body { margin: 0; font-size: 14px; }
.icon-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--rail-width);
  background: #fafafa; border-right: 1px solid var(--border); padding: 0 14px;
}
.brand { height: 77px; display: flex; align-items: center; padding-left: 4px; }
.brand img { width: 148px; height: auto; display: block; mix-blend-mode: multiply; }
.sidebar-title { display: flex; align-items: center; gap: 9px; padding: 14px 8px 10px; border-top: 1px solid var(--border); font-weight: 600; }
.sidebar svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; flex: none; }
#section-nav { display: grid; gap: 4px; padding-left: 14px; }
#section-nav button { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; background: transparent; border-color: transparent; box-shadow: none; font-weight: 450; }
#section-nav button[aria-current] { background: white; border-color: #cbccd2; box-shadow: 0 1px 2px #15192210; }
.workspace { margin-left: var(--rail-width); min-width: 0; }
.page-header { min-height: 77px; display: flex; align-items: center; padding: 16px 23px; border-bottom: 1px solid var(--border); }
h1, h2, h3 { color: #111318; }
h1 { font-size: 25px; font-weight: 600; letter-spacing: -.035em; margin: 0; }
h2 { font-size: 19px; font-weight: 600; letter-spacing: -.025em; margin: 0 0 12px; }
h3 { font-size: 15px; font-weight: 650; margin: 0 0 12px; }
p { line-height: 1.5; color: var(--muted); }
#steps { display: grid; grid-template-columns: repeat(4, 1fr); padding: 18px 20px 15px; border-bottom: 1px solid var(--border); }
#steps button { display: grid; justify-items: center; gap: 6px; position: relative; border: 0; box-shadow: none; background: none; color: var(--muted); padding: 0; font-size: 12px; font-weight: 500; }
#steps button:not(:last-child)::after { content: ""; position: absolute; top: 18px; left: calc(50% + 25px); width: calc(100% - 50px); border-top: 1px solid #dedee3; }
#steps button.complete::after { border-color: var(--success); }
#steps button.complete { color: var(--success); }
.step-dot { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: #eeeeef; color: #686b75; }
#steps button.complete .step-dot { background: #169b49; color: white; }
#steps button[aria-current] { color: #141824; font-weight: 650; }
#steps button[aria-current] .step-dot { background: var(--action); color: white; outline: 1px solid #89909b; outline-offset: 2px; }
.page-content { padding: 19px 17px 36px; }
.card, .board, .inspector { background: var(--paper); border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 1px 2px #1519220d; padding: 20px; }
.form { max-width: 680px; }
button, input, select { font: inherit; }
button { cursor: pointer; border: 1px solid var(--border); border-radius: 6px; padding: 8px 12px; background: var(--paper); color: inherit; box-shadow: 0 1px 2px #15192212; font-size: 13px; font-weight: 550; }
button:disabled { opacity: .53; cursor: default; }
button:hover:not(:disabled) { filter: brightness(.96); }
button.primary { color: white; background: var(--action); border-color: var(--action); }
:focus-visible { outline: 2px solid #205cb1; outline-offset: 2px; }
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
label { display: block; font-size: 13px; font-weight: 550; }
label input:not([type=checkbox]), label select { display: block; width: 100%; margin-top: 5px; padding: 8px; border: 1px solid #d4d5db; border-radius: 6px; background: white; color: inherit; }
input[type=checkbox] { accent-color: var(--action); }
fieldset { border: 1px solid var(--border); border-radius: 8px; margin: 14px 0; padding: 11px; min-width: 0; }
fieldset > label { margin: 6px 0; }
legend { font-size: 13px; font-weight: 650; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 15px; }
.models { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 11px; }
.model { padding: 0; text-align: left; overflow: hidden; border-radius: 11px; }
.model img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.model span { display: block; padding: 12px; }
.model small { display: block; margin-top: 5px; font-weight: 450; }
.editor { display: grid; grid-template-columns: minmax(0, 1fr) minmax(295px, 335px); gap: 13px; align-items: start; }
.board { min-width: 0; }
.inspector { padding: 15px; }
.plan { display: block; width: 100%; height: clamp(350px, 55vh, 650px); touch-action: none; background: #fafafb; border: 1px solid var(--border); border-radius: 7px; }
.plan [data-id] { cursor: grab; }
.plan [data-id]:active { cursor: grabbing; }
.plan text { user-select: none; }
.caption { font-size: 13px; margin: 9px 0; }
.alert { background: #fff8eb; color: #753700; padding: 9px 13px; border: 1px solid #f0d4ad; border-radius: 7px; margin-bottom: 12px; }
.surface { padding: 8px 0; border-bottom: 1px solid var(--border); }
.surface:last-child { border: 0; }
.surface .fields { margin-top: 6px; }
.surface label { font-size: 12px; }
.table { overflow: auto; margin: 15px 0; }
table { border-collapse: collapse; width: 100%; font-size: 13px; }
th, td { padding: 9px 10px; text-align: left; border-bottom: 1px solid var(--border); white-space: nowrap; }
th { background: #f1f1f3; }
small { color: var(--muted); }
[hidden] { display: none !important; }
summary { cursor: pointer; font-weight: 650; margin: 13px 0 7px; }
@media (max-width: 1100px) { :root { --rail-width: 191px; } .editor { grid-template-columns: 1fr; } }
@media (max-width: 700px) {
  .sidebar { position: static; width: auto; padding: 0 16px; border: 0; border-bottom: 1px solid var(--border); }
  .brand { height: 53px; padding: 0; }
  .brand img { width: 120px; }
  .sidebar-title, #section-nav { display: none; }
  .workspace { margin-left: 0; }
  .page-header { min-height: 59px; padding: 12px 14px; }
  h1 { font-size: 22px; }
  #steps { padding: 12px 8px; }
  .page-content { padding: 12px 10px 24px; }
  .card, .board { padding: 13px; }
  .plan { height: 365px; }
}
@page { size: A4 landscape; margin: 12mm; }
@media print {
  .sidebar, .page-header, #steps, .actions, #notice { display: none !important; }
  body { background: white; }
  .workspace { margin: 0; }
  .page-content, .card { padding: 0; }
  .card { border: 0; box-shadow: none; }
  .table { overflow: visible; }
  table { font-size: 9px; }
  th, td { padding: 5px; }
  tr { break-inside: avoid; }
}
