:root {
  --floating-bg: #f7f7f5;
  --floating-paper: #ffffff;
  --floating-ink: #202124;
  --floating-muted: #74777c;
  --floating-line: #e0e2e5;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { width: 100%; min-width: 0; height: 100%; margin: 0; overflow: hidden; }
body { color: var(--floating-ink); background: var(--floating-bg); }
button, textarea, select { font: inherit; }
button { cursor: pointer; }
button:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--floating-accent, #5c4fe6) 24%, transparent);
  outline-offset: 2px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.floating-shell {
  --floating-accent: #5c4fe6;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  height: 100%;
  min-height: 0;
  background: var(--floating-paper);
  border-top: 3px solid var(--floating-accent);
}
.floating-head {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 9px 10px 7px;
  border-bottom: 1px solid var(--floating-line);
}
.floating-project-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--floating-accent);
}
.floating-project-label { min-width: 0; flex: 1 1 auto; }
.floating-project-label select {
  width: 100%;
  min-width: 0;
  height: 32px;
  padding: 4px 26px 4px 4px;
  border: 0;
  border-radius: 7px;
  color: var(--floating-ink);
  background: transparent;
  font-size: .86rem;
  font-weight: 700;
  text-overflow: ellipsis;
}
.floating-project-label select:hover { background: #f1f2f3; }
.floating-project-label select:disabled { opacity: 1; cursor: default; }

.floating-form {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  min-height: 0;
  padding: 10px;
}
.floating-form textarea {
  width: 100%;
  min-width: 0;
  min-height: 0;
  resize: none;
  padding: 2px 2px 10px;
  border: 0;
  outline: 0;
  color: var(--floating-ink);
  background: transparent;
  font-size: .96rem;
  line-height: 1.55;
}
.floating-form textarea::placeholder { color: #a2a5aa; }
.floating-form textarea:disabled { opacity: .7; }
.floating-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 40px;
}
.floating-status {
  min-width: 0;
  overflow: hidden;
  color: var(--floating-muted);
  font-size: .72rem;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.floating-status[data-state="success"] { color: #137333; }
.floating-status[data-state="error"] { color: #b3261e; }
.floating-add {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  border-radius: 10px;
  color: #fff;
  background: var(--floating-accent);
}
.floating-add:hover { filter: brightness(.94); }
.floating-add:active { transform: translateY(1px); }
.floating-add:disabled { cursor: default; opacity: .52; }
.floating-add svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

@media (max-height: 210px) {
  .floating-head { padding-block: 6px 5px; }
  .floating-form { padding-block: 7px; }
  .floating-footer { min-height: 34px; }
  .floating-add { width: 34px; height: 34px; }
}
