/* TextPouch — Personal writing pocketbook */

/* Folio tab bar & drawer trigger */
.pocketbook {
  position: relative;
}

.folio-bar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: -1px;
  position: relative;
  z-index: 2;
}

.folio-tabs {
  display: flex;
  align-items: flex-end;
  gap: 0.25rem;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 2px 2px 0;
}

.folio-tabs::-webkit-scrollbar {
  display: none;
}

.folio-tab {
  position: relative;
  flex: none;
  display: inline-flex;
  align-items: center;
  padding: 0.54rem 0.92rem 0.6rem;
  border: 1px solid transparent;
  border-bottom: 0;
  border-radius: 10px 10px 0 0;
  font-size: 0.84rem;
  font-weight: 550;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
  transition: color 140ms ease, background-color 140ms ease;
}

.folio-tab:hover {
  color: var(--text);
  background: light-dark(rgba(255, 253, 248, 0.55), rgba(38, 33, 45, 0.55));
}

.folio-tab[aria-current="true"] {
  background: var(--paper);
  color: var(--text);
  font-weight: 650;
  border-color: var(--hair);
  box-shadow: 0 -2px 0 inset var(--paper);
}

.folio-tab[aria-current="true"]::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 12px;
  right: 12px;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: var(--brass);
}

.drawer-trigger {
  flex: none;
  margin-bottom: 0.42rem;
  min-height: 36px;
  padding: 0.32rem 0.72rem;
  border-radius: var(--radius-pill);
  border-color: var(--hair);
  background: var(--paper);
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 600;
}

.drawer-trigger .ico {
  width: 15px;
  height: 15px;
  color: var(--action);
}

.pill-count {
  display: inline-grid;
  place-items: center;
  min-width: 1.35rem;
  height: 1.25rem;
  padding: 0 0.34rem;
  border-radius: var(--radius-pill);
  background: var(--wash);
  color: var(--action);
  font-size: 0.74rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* Manuscript folio sheet */
.folio-sheet {
  position: relative;
  border: 1px solid var(--hair);
  border-radius: 0 var(--radius-folio) var(--radius-folio) var(--radius-folio);
  background-color: var(--paper);
  background-image:
    linear-gradient(180deg, light-dark(rgba(216, 165, 92, 0.03), rgba(226, 179, 107, 0.025)) 0%, transparent 110px);
  box-shadow:
    0 1px 2px var(--elev),
    0 14px 36px -12px var(--elev);
  overflow: hidden;
}

.sheet-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 0.65rem 1.25rem;
  border-bottom: 1px solid var(--hair);
  background: light-dark(rgba(244, 237, 227, 0.42), rgba(48, 42, 56, 0.42));
  flex-wrap: wrap;
}

.sheet-meta {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.sheet-meta label {
  font-family: var(--heading);
  font-size: 1.02rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.draft-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.18rem 0.56rem;
  border-radius: var(--radius-pill);
  font-size: 0.73rem;
  font-weight: 650;
  letter-spacing: 0.02em;
  background: var(--wash);
  color: var(--muted);
  border: 1px solid var(--hair);
}

.draft-pill::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--hair-strong);
}

.folio-sheet[data-empty="false"] .draft-pill {
  color: var(--action);
  border-color: light-dark(rgba(120, 71, 149, 0.25), rgba(220, 174, 235, 0.3));
}

.folio-sheet[data-empty="false"] .draft-pill::before {
  background: var(--brass);
}

.sheet-top-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem 0.9rem;
  flex-wrap: wrap;
}

.lang-control {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
}

.lang-control select {
  width: auto;
  min-width: 7.4rem;
  min-height: 34px;
  margin-top: 0;
  padding: 0.25rem 1.7rem 0.25rem 0.6rem;
  font-size: 0.82rem;
  border-color: var(--hair);
  background: var(--paper);
}

.small-btn {
  min-height: 36px;
  padding: 0.35rem 0.68rem;
  font-size: 0.82rem;
}

.small-btn .ico {
  width: 15px;
  height: 15px;
}

.sheet-top .small-btn {
  color: var(--action);
}

/* Full-width manuscript writing canvas */
.sheet-body {
  position: relative;
}

.sheet-body::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 2.35rem;
  width: 1px;
  background: light-dark(rgba(216, 165, 92, 0.28), rgba(226, 179, 107, 0.16));
  pointer-events: none;
}

#editor {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 0;
  background: transparent;
  min-height: 15.5rem;
  height: clamp(15.5rem, 36vh, 23rem);
  resize: vertical;
  padding: 1.5rem clamp(1.4rem, 4vw, 3.35rem) 2.2rem 3.55rem;
  font-family: var(--heading);
  font-size: clamp(1.12rem, 1.55vw, 1.3rem);
  line-height: 1.78;
  color: var(--text);
  caret-color: var(--action);
}

#editor::placeholder {
  color: light-dark(#8b7f93, #8f809b);
  font-style: italic;
}

#editor:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 2px var(--action);
}

.sheet-cue {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.42rem 1.25rem 0.6rem 3.55rem;
  font-size: 0.77rem;
  color: var(--muted);
  transition: opacity 160ms ease;
}

.folio-sheet[data-empty="false"] .sheet-cue {
  opacity: 0.72;
}

.cue-mark {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.cue-mark .ico {
  width: 13px;
  height: 13px;
  color: var(--action);
}

.cue-hint {
  color: var(--muted);
}

/* Unified metrics & command ledger */
.sheet-ledger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.25rem;
  padding: 0.62rem 1.25rem;
  border-top: 1px solid var(--hair);
  background: var(--wash);
  flex-wrap: wrap;
}

.ribbon {
  display: flex;
  align-items: baseline;
  gap: 0.35rem 1.35rem;
  margin: 0;
  flex-wrap: wrap;
}

.ribbon div {
  display: flex;
  align-items: baseline;
  gap: 0.42rem;
}

.ribbon div + div {
  padding-left: 1.15rem;
  border-left: 1px solid var(--hair);
}

.ribbon dt {
  font-size: 0.78rem;
  font-weight: 550;
  color: var(--muted);
}

.ribbon dd {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  color: var(--action);
}

.command {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.command .small-btn {
  color: var(--text);
}

#editor-status {
  padding: 0.5rem 1.25rem;
  border-top: 1px solid var(--hair);
  background: light-dark(rgba(216, 165, 92, 0.1), rgba(226, 179, 107, 0.08));
  color: var(--text);
  font-weight: 550;
}

/* Tool options, Proof sheet, and Report ledger */
.tool-options:empty {
  display: none;
}

.options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr));
  gap: 0.85rem 1rem;
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--hair);
  background: light-dark(rgba(244, 237, 227, 0.35), rgba(48, 42, 56, 0.35));
}

.options label {
  color: var(--muted);
  font-size: 0.8rem;
  letter-spacing: 0.01em;
}

.options input,
.options select {
  margin-top: 0.32rem;
  font-size: 0.9rem;
  color: var(--text);
}

.extras {
  padding: 1.1rem 1.25rem 1.25rem;
  border-top: 1px dashed var(--hair-strong);
  background: var(--proof);
}

.extras-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.extras-title {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.extras h2 {
  font-size: 1.08rem;
  font-weight: 650;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.16rem 0.56rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--hair);
  background: var(--paper);
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 650;
}

.badge[data-state="ready"] {
  color: var(--action);
  border-color: light-dark(rgba(120, 71, 149, 0.35), rgba(220, 174, 235, 0.4));
  background: light-dark(rgba(120, 71, 149, 0.08), rgba(220, 174, 235, 0.12));
}

.proof-sheet textarea {
  display: block;
  width: 100%;
  min-height: 7.5rem;
  resize: vertical;
  padding: 0.95rem 1.1rem;
  font-family: var(--heading);
  font-size: 1.04rem;
  line-height: 1.65;
  background: var(--paper);
  border-color: var(--hair);
}

body[data-tool="text-to-slug"] .proof-sheet textarea,
body[data-tool="normalize-unicode"] .proof-sheet textarea {
  font-family: var(--mono);
  font-size: 0.95rem;
}

.report-body dl {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
  gap: 0.65rem;
  margin: 0;
}

.report-row {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.72rem 0.9rem;
  border: 1px solid var(--hair);
  border-radius: var(--radius-control);
  background: var(--paper);
}

.report-row-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
}

.report-row dt {
  font-size: 0.84rem;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.report-row dd {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  color: var(--action);
}

.freq-meter {
  width: 100%;
  height: 6px;
  border-radius: 99px;
  overflow: hidden;
  appearance: none;
  background: var(--wash);
}

.freq-meter::-webkit-meter-bar {
  background: var(--wash);
  border: 0;
  border-radius: 99px;
}

.freq-meter::-webkit-meter-optimum-value {
  background: var(--action);
  border-radius: 99px;
}

.freq-meter::-moz-meter-bar {
  background: var(--action);
  border-radius: 99px;
}

.report-empty {
  color: var(--muted);
  font-size: 0.9rem;
  font-style: italic;
}

/* Pocketbook slide-over drawer (desktop) & bottom sheet (mobile) */
.pocket-drawer {
  margin: 0 0 0 auto;
  height: 100dvh;
  max-height: 100dvh;
  width: min(100%, 26.5rem);
  border: 0;
  border-left: 1px solid var(--hair-strong);
  border-radius: 16px 0 0 16px;
  padding: 1.35rem 1.35rem 2rem;
  overflow-y: auto;
}

.drawer-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--hair);
}

.drawer-kicker {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.11em;
  color: var(--brass-text);
  margin-bottom: 0.18rem;
}

.drawer-note {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 0.85rem 0 1.1rem;
  padding: 0.65rem 0.8rem;
  border-radius: var(--radius-control);
  background: var(--wash);
  font-size: 0.81rem;
  color: var(--muted);
}

.drawer-note .ico {
  width: 15px;
  height: 15px;
  margin-top: 0.12rem;
  color: var(--action);
}

.drawer-group + .drawer-group {
  margin-top: 1.2rem;
  padding-top: 1.05rem;
  border-top: 1px solid var(--hair);
}

.drawer-group h3 {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-family: var(--ui);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 0.5rem;
}

.drawer-group h3 .ico {
  color: var(--action);
  width: 16px;
  height: 16px;
}

.drawer-group ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.28rem;
}

.drawer-group a {
  display: block;
  padding: 0.55rem 0.72rem;
  border-radius: var(--radius-control);
  border: 1px solid transparent;
  text-decoration: none;
  color: inherit;
  transition: background-color 120ms ease, border-color 120ms ease;
}

.drawer-group a:hover {
  background: var(--wash);
  border-color: var(--hair);
}

.drawer-group a[aria-current="true"] {
  background: var(--wash);
  border-color: var(--brass);
}

.drawer-title {
  display: block;
  font-weight: 650;
  font-size: 0.9rem;
  color: var(--text);
}

.drawer-group a[aria-current="true"] .drawer-title {
  color: var(--action);
}

.drawer-desc {
  display: block;
  font-size: 0.79rem;
  color: var(--muted);
  margin-top: 0.12rem;
  line-height: 1.4;
}

/* Editorial lower page — Fieldnotes spread */
.fieldnotes {
  margin-top: 2.85rem;
  display: grid;
  gap: 2.25rem;
}

.notes-spread {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.4rem;
}

.note-card {
  padding: 1.35rem 1.45rem;
  border: 1px solid var(--hair);
  border-radius: var(--radius-folio);
  background: var(--paper);
}

.note-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--brass-text);
  margin-bottom: 0.35rem;
}

.note-card h2 {
  margin-bottom: 0.65rem;
}

.note-card p {
  color: var(--muted);
  font-size: 0.94rem;
}

.manuscript-quote {
  margin-top: 0.25rem;
  padding: 0.85rem 1rem;
  border-left: 3px solid var(--brass);
  border-radius: 0 8px 8px 0;
  background: var(--wash);
  font-family: var(--heading);
  font-size: 0.98rem;
  line-height: 1.62;
  color: var(--text);
}

.manuscript-quote p {
  color: var(--text);
  font-size: 0.98rem;
}

.method-more {
  margin-top: 0.85rem;
  font-size: 0.88rem;
  font-weight: 600;
}

/* Companion shelf & tool directory cards */
.companion-shelf {
  padding-top: 2rem;
  border-top: 1px solid var(--hair);
}

.shelf-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.25rem;
}

.shelf-copy {
  margin-top: 0.45rem;
  max-width: 62ch;
  color: var(--muted);
  font-size: 0.94rem;
}

.inline-link {
  font-weight: 600;
}

.shelf-art {
  flex: none;
  width: 210px;
}

.directory {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15.5rem), 1fr));
  gap: 0.95rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.dir-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 1.05rem 1.15rem;
  border: 1px solid var(--hair);
  border-radius: var(--radius-folio);
  background: var(--paper);
  text-decoration: none;
  color: inherit;
  transition: border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}

.dir-card:hover {
  border-color: var(--action);
  box-shadow: 0 8px 20px -8px var(--elev);
  transform: translateY(-1px);
}

.dir-head {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.65rem;
}

.dir-icon {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: var(--wash);
  color: var(--action);
}

.dir-cat {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.dir-arrow {
  margin-left: auto;
  color: var(--muted);
  transition: transform 150ms ease, color 150ms ease;
}

.dir-card:hover .dir-arrow {
  color: var(--action);
  transform: translateX(2px);
}

.dir-title {
  font-family: var(--heading);
  font-size: 1.05rem;
  font-weight: 650;
  color: var(--text);
  margin-bottom: 0.32rem;
}

.dir-card p {
  font-size: 0.87rem;
  line-height: 1.5;
  color: var(--muted);
}

/* Bookplate SVG theme adaptation */
.bookplate-art {
  display: block;
  width: 100%;
  height: auto;
}

.bp-cover {
  fill: var(--wash);
  stroke: var(--hair-strong);
  stroke-width: 1.2;
}

.bp-spine {
  stroke: var(--hair-strong);
  stroke-width: 1.2;
}

.bp-page {
  fill: var(--paper);
  stroke: var(--hair);
  stroke-width: 1;
}

.bp-margin {
  stroke: var(--brass);
  stroke-opacity: 0.55;
  stroke-width: 1.1;
}

.bp-lines {
  stroke: var(--text);
  stroke-opacity: 0.26;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.bp-metrics {
  stroke: var(--action);
  stroke-width: 2.4;
  stroke-linecap: round;
}

.bp-ribbon {
  fill: var(--brass);
}

.bp-dot {
  fill: var(--action);
}

/* Directory, hub, and editorial prose pages */
.hub-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.1rem 1.35rem;
  border: 1px solid var(--hair);
  border-radius: var(--radius-folio);
  background: var(--paper);
  margin-bottom: 2.2rem;
}

.hub-art {
  flex: none;
  width: 190px;
}

.group-links {
  display: flex;
  gap: 0.55rem;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  margin: 0;
}

.group-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  padding: 0.45rem 0.82rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--hair);
  background: var(--wash);
  color: var(--text);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
}

.group-pill .ico {
  width: 15px;
  height: 15px;
  color: var(--action);
}

.group-pill:hover {
  border-color: var(--action);
  color: var(--action);
}

.index-group + .index-group {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--hair);
}

.index-group-head {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  margin-bottom: 1.15rem;
}

.index-icon {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--wash);
  border: 1px solid var(--hair);
  color: var(--action);
  flex: none;
}

.index-group-head h2 a {
  color: var(--text);
  text-decoration: none;
}

.index-group-head h2 a:hover {
  color: var(--action);
  text-decoration: underline;
}

.index-group-head p {
  margin-top: 0.25rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.hub-back {
  margin-bottom: 1.1rem;
  font-size: 0.88rem;
  font-weight: 600;
}

.editorial-spread {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 18rem;
  gap: 2.2rem;
  align-items: start;
}

.article {
  max-width: 66ch;
  padding-bottom: 1.5rem;
}

.article .lead {
  font-family: var(--heading);
  font-size: 1.15rem;
  line-height: 1.65;
  color: var(--text);
  margin-bottom: 1.1rem;
}

.article h2 {
  margin-bottom: 0.55rem;
}

.article h2:not(:first-child) {
  margin-top: 1.65rem;
}

.article p {
  color: var(--muted);
}

.method-item {
  padding-top: 1.25rem;
  margin-top: 1.25rem;
  border-top: 1px solid var(--hair);
}

.method-item h2 {
  margin-top: 0;
  font-size: 1.18rem;
}

.editorial-aside {
  padding: 1.25rem;
  border: 1px solid var(--hair);
  border-radius: var(--radius-folio);
  background: var(--paper);
}

.editorial-aside p {
  margin-top: 0.85rem;
  font-size: 0.87rem;
  color: var(--muted);
}

.cta-row {
  margin-top: 1.35rem;
}

.button-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.6rem 1.05rem;
  border-radius: var(--radius-control);
  background: var(--action);
  color: var(--on-primary);
  font-weight: 650;
  font-size: 0.9rem;
  text-decoration: none;
}

.button-link:hover {
  filter: brightness(1.06);
  text-decoration: none;
}

/* Responsive adjustments */
@media (max-width: 900px) {
  .metric-secondary {
    display: none !important;
  }
  .editorial-spread {
    grid-template-columns: 1fr;
  }
  .shelf-art, .hub-art {
    display: none;
  }
}

@media (max-width: 720px) {
  .folio-bar {
    gap: 0.45rem;
  }
  .folio-tab {
    padding: 0.48rem 0.72rem 0.52rem;
    font-size: 0.8rem;
  }
  .drawer-trigger {
    padding: 0.3rem 0.58rem;
    font-size: 0.79rem;
    margin-bottom: 0.32rem;
  }
  .folio-sheet {
    border-radius: 0 var(--radius-folio) var(--radius-folio) var(--radius-folio);
  }
  .sheet-top {
    padding: 0.55rem 0.8rem;
    gap: 0.45rem;
  }
  .sheet-meta label {
    font-size: 0.94rem;
  }
  .sheet-top-actions {
    width: 100%;
    justify-content: space-between;
    gap: 0.4rem;
  }
  .lang-control span {
    display: none;
  }
  .lang-control select {
    min-width: 6.4rem;
    min-height: 36px;
  }
  .sheet-body::before {
    display: none;
  }
  #editor {
    padding: 1rem 0.9rem 1.2rem;
    min-height: 11rem;
    height: clamp(11rem, 29svh, 16rem);
    font-size: 1.08rem;
    line-height: 1.7;
  }
  .sheet-cue {
    padding: 0.35rem 0.85rem 0.55rem;
  }
  .cue-hint {
    display: none;
  }
  .sheet-ledger {
    flex-direction: column;
    align-items: stretch;
    padding: 0;
    gap: 0;
  }
  .ribbon {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
    border-bottom: 1px solid var(--hair);
  }
  .ribbon div {
    flex-direction: column-reverse;
    align-items: flex-start;
    gap: 0.08rem;
    padding: 0.5rem 0.72rem;
  }
  .ribbon div + div {
    padding-left: 0.72rem;
  }
  .ribbon dt {
    font-size: 0.72rem;
  }
  .ribbon dd {
    font-size: 0.95rem;
  }
  .command {
    padding: 0.5rem 0.7rem;
  }
  .command .actions {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.3rem;
  }
  .command .small-btn {
    padding: 0.4rem 0.3rem;
    min-height: 40px;
    font-size: 0.76rem;
    gap: 0.25rem;
    justify-content: center;
  }
  .command .small-btn .ico {
    width: 14px;
    height: 14px;
  }
  .options, .extras {
    padding: 0.85rem 0.8rem;
  }
  .notes-spread {
    grid-template-columns: 1fr;
  }
  .note-card {
    padding: 1.1rem 1.1rem;
  }
  .pocket-drawer {
    margin: auto 0 0 0;
    width: 100%;
    height: auto;
    max-height: 82dvh;
    border-left: 0;
    border-top: 1px solid var(--hair-strong);
    border-radius: 18px 18px 0 0;
    padding: 1.15rem 1.1rem 1.6rem;
  }
}

@media (max-width: 390px) {
  .command .small-btn span {
    font-size: 0.72rem;
  }
  .sheet-top .small-btn {
    padding: 0.32rem 0.52rem;
    font-size: 0.78rem;
  }
}
