:root {
  --focus: #d94f30;
  --cmd-bg: #fffcf5;
  --cmd-text: #211f1a;
  --cmd-line: #cbc6ba;
  --cmd-focus: #f2e8d8;
  --cmd-radius: 12px;
}

body.design-board {
  overflow: hidden;
  background: #deddd7;
  color: #211f1a;
}
.fb-shell {
  display: grid;
  grid-template-rows: 64px 48px minmax(0, 1fr) 34px;
  min-height: 100dvh;
}
.fb-top {
  display: grid;
  grid-template-columns: 178px minmax(0, 1fr) auto;
  align-items: stretch;
  border-bottom: 1px solid #bebcb5;
  background: #fffcf5;
}
.fb-brand {
  display: flex;
  align-items: center;
  padding: 0 18px;
  border-right: 1px solid #cbc8c0;
}
.fb-brand .brand-logo {
  width: 100px;
  filter: invert(1);
}
.fb-sections {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 2px;
  padding: 0 12px;
  overflow-x: auto;
}
.fb-sections button {
  min-height: 36px;
  flex: 0 0 auto;
  padding: 0 11px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #74716a;
  font-size: 10.5px;
}
.fb-sections button.is-active {
  background: #ebe7dc;
  color: #211f1a;
  font-weight: 680;
}
.fb-top-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 10px;
  border-left: 1px solid #cbc8c0;
}
.fb-top-actions button {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid #cbc8c0;
  border-radius: 8px;
  background: #fff;
  font-size: 10px;
}
.fb-top-actions .primary {
  border-color: #211f1a;
  background: #211f1a;
  color: #fff;
}

.fb-toolbar {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto minmax(180px, 1fr);
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  border-bottom: 1px solid #bebcb5;
  background: #f3f1ea;
}
.fb-title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.fb-title h1 {
  margin: 0;
  font-size: 13px;
}
.fb-title span {
  color: #88857d;
  font-size: 9px;
}
.fb-view-tabs {
  display: flex;
  gap: 3px;
  padding: 3px;
  border: 1px solid #d0ccc3;
  border-radius: 9px;
  background: #e7e4dc;
}
.fb-view-tabs button {
  min-height: 28px;
  padding: 0 9px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #77736b;
  font-size: 9px;
}
.fb-view-tabs button.is-active {
  background: #fff;
  color: #211f1a;
  box-shadow: 0 1px 3px rgba(42, 38, 29, 0.08);
}
.fb-filter {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}
.fb-filter button {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  gap: 6px;
  padding: 0 8px;
  border: 1px solid #cbc8c0;
  border-radius: 7px;
  background: #fdfbf6;
  color: #67645e;
  font-size: 9px;
}

.fb-canvas-wrap {
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background-color: #e8e7e1;
  background-image:
    linear-gradient(#d7d6d0 1px, transparent 1px),
    linear-gradient(90deg, #d7d6d0 1px, transparent 1px);
  background-size: 24px 24px;
}
.fb-board {
  display: grid;
  grid-auto-columns: minmax(260px, 1fr);
  grid-auto-flow: column;
  gap: 10px;
  width: 100%;
  height: 100%;
  padding: 12px 12px 78px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
}
.fb-column {
  display: grid;
  grid-template-rows: 42px minmax(0, 1fr) 38px;
  min-width: 260px;
  overflow: hidden;
  border: 1px solid #c6c3bb;
  border-radius: 12px;
  background: rgba(250, 248, 242, 0.96);
  scroll-snap-align: start;
}
.fb-column-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 11px;
  border-bottom: 1px solid #d3d0c7;
}
.fb-column-head .bar {
  width: 4px;
  height: 18px;
  border-radius: 3px;
  background: #d94f30;
}
.fb-column:nth-child(2) .bar {
  background: #dba72d;
}
.fb-column:nth-child(3) .bar {
  background: #7b7f75;
}
.fb-column:nth-child(4) .bar {
  background: #2e8b61;
}
.fb-column-head strong {
  font-size: 10.5px;
}
.fb-column-head span {
  margin-left: auto;
  color: #8e8a82;
  font:
    9px ui-monospace,
    monospace;
}
.fb-stack {
  min-height: 0;
  overflow-y: auto;
  padding: 8px;
}
.fb-card {
  margin-bottom: 8px;
  padding: 11px;
  border: 1px solid #d5d1c8;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 2px 7px rgba(54, 49, 38, 0.04);
}
.fb-card-top {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #8c8880;
  font:
    8.5px ui-monospace,
    monospace;
}
.fb-card-top .sample-tag {
  margin-left: auto;
}
.fb-card h2 {
  margin: 9px 0 0;
  font-size: 11px;
  line-height: 1.35;
}
.fb-card p {
  margin: 5px 0 0;
  color: #77736c;
  font-size: 9.5px;
  line-height: 1.4;
}
.fb-card-foot {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 11px;
}
.fb-card-foot span {
  display: inline-flex;
  min-height: 22px;
  align-items: center;
  padding: 0 6px;
  border: 1px solid #ddd9d0;
  border-radius: 6px;
  color: #77736c;
  font-size: 8.5px;
}
.fb-card-foot button {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  margin-left: auto;
  border: 0;
  border-radius: 5px;
  background: #f2efe8;
}
.fb-card.is-focus {
  border-color: #d94f30;
  box-shadow: inset 3px 0 #d94f30;
}
.fb-card.is-blocked {
  border-color: #c98d7e;
  background: #fff4f1;
}
.fb-card.is-blocked h2 {
  color: #8e3e2c;
}
.fb-card.is-blocked .fb-card-foot span {
  border-color: #ddb1a7;
  color: #8e3e2c;
}
.fb-empty {
  display: grid;
  min-height: 124px;
  place-items: center;
  padding: 16px;
  border: 1px dashed #c5c1b7;
  border-radius: 9px;
  color: #8a867e;
  text-align: center;
}
.fb-empty strong {
  display: block;
  color: #5d5a54;
  font-size: 10px;
}
.fb-empty p {
  margin: 4px 0 0;
  font-size: 9px;
  line-height: 1.4;
}
.fb-add {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 0;
  border-top: 1px solid #d3d0c7;
  background: #f4f1ea;
  color: #69665f;
  font-size: 9.5px;
}

.fb-dock {
  position: absolute;
  right: 50%;
  bottom: 14px;
  z-index: 10;
  display: flex;
  min-height: 46px;
  align-items: center;
  gap: 4px;
  padding: 5px;
  border: 1px solid #bdb9b0;
  border-radius: 12px;
  background: #211f1a;
  color: #fff;
  box-shadow: 0 12px 30px rgba(41, 36, 27, 0.18);
  transform: translateX(50%);
}
.fb-dock button {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #c8c4bb;
  font-size: 9.5px;
}
.fb-dock button:hover {
  background: #38352e;
  color: #fff;
}
.fb-dock button.is-active {
  background: #fff;
  color: #211f1a;
}
.fb-dock .divider {
  width: 1px;
  height: 24px;
  background: #4d4941;
}

.fb-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 10px;
  border-top: 1px solid #bebcb5;
  background: #f3f1ea;
  color: #85827a;
  font:
    9px ui-monospace,
    monospace;
  text-transform: uppercase;
}
.fb-foot .sample-tag {
  margin-left: auto;
}

@media (max-width: 760px) {
  body.design-board {
    overflow: auto;
    padding-bottom: 54px;
  }
  .fb-shell {
    display: block;
  }
  .fb-top {
    position: sticky;
    top: 0;
    z-index: 30;
    grid-template-columns: 1fr auto;
    min-height: 56px;
  }
  .fb-brand {
    border-right: 0;
  }
  .fb-brand .brand-logo {
    width: 90px;
  }
  .fb-sections {
    position: fixed;
    z-index: 50;
    inset: 58px 12px auto;
    display: none;
    padding: 10px;
    border: 1px solid #cbc8c0;
    border-radius: 12px;
    background: #fffcf5;
    box-shadow: 0 18px 50px rgba(45, 40, 31, 0.16);
  }
  .nav-open .fb-sections {
    display: grid;
  }
  .fb-sections button {
    text-align: left;
  }
  .fb-top-actions .primary span {
    display: none;
  }
  .fb-top-actions button {
    width: 36px;
    padding: 0;
    justify-content: center;
  }
  .fb-toolbar {
    grid-template-columns: 1fr auto;
    min-height: 48px;
    padding-inline: 8px;
  }
  .fb-title span {
    display: none;
  }
  .fb-view-tabs {
    display: none;
  }
  .fb-filter button:not(:last-child) {
    display: none;
  }
  .fb-canvas-wrap {
    min-height: calc(100dvh - 104px);
  }
  .fb-board {
    grid-auto-columns: calc(100vw - 32px);
    padding: 10px 10px 72px;
  }
  .fb-column {
    min-width: calc(100vw - 32px);
  }
  .fb-dock {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    justify-content: space-around;
    min-height: 54px;
    border: 0;
    border-top: 1px solid #4d4941;
    border-radius: 0;
    transform: none;
  }
  .fb-dock button span {
    display: none;
  }
  .fb-foot {
    min-height: 32px;
  }
}
