body {
  font-family: 'Inter', sans-serif;
}
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #0f172a;
}
::-webkit-scrollbar-thumb {
  background: #334155;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #475569;
}
#expandModal {
  padding: 0;
}
#expandModal .editor-shell {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  border-radius: 0;
  border: 0;
  display: flex;
  flex-direction: column;
}
#expandSummary {
  resize: none;
}
#expandContent {
  flex: 1;
  min-height: 0;
  resize: none;
}
.prompt-explain {
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(129, 140, 248, 0.28);
  border-radius: 0.9rem;
  padding: 0.85rem 1rem;
  color: #e2e8f0;
  font-size: 0.925rem;
  line-height: 1.45;
}
.prompt-explain .label {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #a5b4fc;
}
.prompt-fold summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #c7d2fe;
  font-size: 0.75rem;
  font-weight: 700;
}
.prompt-fold summary::-webkit-details-marker {
  display: none;
}
.prompt-fold summary::before {
  content: "▸";
  color: #818cf8;
}
.prompt-fold[open] summary::before {
  content: "▾";
}
.prompt-fold summary .when-open {
  display: none;
}
.prompt-fold[open] summary .when-closed {
  display: none;
}
.prompt-fold[open] summary .when-open {
  display: inline;
}
select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='%2394a3b8' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
  padding-right: 2.75rem !important;
}
.stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.55rem;
  border-radius: 0.75rem;
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid rgba(51, 65, 85, 0.7);
  font-size: 11px;
  color: #cbd5e1;
}
.category-picker .new-cat-field {
  display: none;
  width: 100%;
}
.category-picker:has(select option[value="__new__"]:checked) .new-cat-field {
  display: block;
  margin-top: 0.5rem;
}
.star-row {
  display: inline-flex;
  flex-direction: row-reverse;
  gap: 1px;
}
.star-row button {
  background: none;
  border: 0;
  color: #475569;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 2px;
}
.star-row button.is-on,
.star-row button.is-on ~ button,
.star-row button:hover,
.star-row button:hover ~ button {
  color: #fbbf24;
}

/* Slider de Historial estilo Simplenote */
#historyRange {
  -webkit-appearance: none;
  background: #334155;
  height: 6px;
  border-radius: 4px;
  outline: none;
}
#historyRange::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 22px;
  border-radius: 4px;
  background: #f1f5f9;
  cursor: ew-resize;
  box-shadow: 0 2px 5px rgba(0,0,0,0.4);
  transition: transform 0.1s ease;
}
#historyRange::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  background: #ffffff;
}
