/* V0.13.1 layer: one-line quick index, simplified project/goal/task entry, periodic finance report card. */

/* ---------- Quick index: never wrap character by character ---------- */
.v12-qi button[data-qi] { white-space: nowrap; overflow-wrap: normal; word-break: keep-all; max-width: 16em; overflow: hidden; text-overflow: ellipsis; line-height: 1.3; }
.v12-qi .v12-qi-short { display: none; }
.v12-qi .v12-qi-full { display: inline; }
@media (max-width: 900px) {
  .v12-qi .v12-qi-short { display: inline; }
  .v12-qi .v12-qi-full { display: none; }
  .v12-qi.v12-qi-open ol {
    min-width: 7.5em; max-width: min(62vw, 13em); width: max-content;
    /* stays between the status bar and the bottom navigation; scrolls inside, never the page sideways */
    max-height: calc(100dvh - var(--v12-nav-h) - 24px - env(safe-area-inset-bottom, 0px) - 46px - env(safe-area-inset-top, 0px) - 24px);
    overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; box-sizing: border-box;
  }
  .v12-qi button[data-qi] { min-height: 44px; max-width: 100%; padding: 6px 14px; text-align: left; }
}

/* ---------- Simplified entry (project / goal / task) ---------- */
.v131-quick { display: grid; gap: 14px; }
.v131-quick .v131-title { font-size: 18px; font-weight: 650; min-height: 52px; }
.v131-quick .v131-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.v131-kinds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 4px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); }
.v131-kinds button { min-height: 44px; border: 0; border-radius: 9px; background: transparent; color: var(--muted); font-weight: 650; }
.v131-kinds button[aria-checked="true"] { background: var(--surface); color: var(--brand); box-shadow: var(--shadow-card); }
.v131-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.v131-chips button { min-height: 38px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); font-size: 13px; }
.v131-chips button[aria-pressed="true"] { border-color: var(--brand-2); background: var(--brand-soft); color: var(--brand); font-weight: 650; }
.v131-hint { margin: -6px 0 0; }
.v131-more > summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; color: var(--brand-2); font-weight: 650; }
.v131-more[open] > summary { margin-bottom: 6px; }
.v131-foot { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
.v131-foot button { min-height: 46px; padding: 0 20px; white-space: nowrap; }
#v131-entry-dialog .dialog-heading { margin: 0 0 4px; padding: 0; display: flex; justify-content: space-between; align-items: center; }
#v131-entry-dialog .dialog-heading h2 { margin: 0; }
.v131-new-fab { display: none; }
@media (max-width: 900px) {
  #v131-entry-dialog { width: 100%; max-width: none; margin: auto 0 0; border-radius: 22px 22px 0 0; max-height: 92dvh; padding: 18px 16px calc(18px + env(safe-area-inset-bottom, 0px)); }
  .v131-quick .v131-row { grid-template-columns: 1fr 1fr; }
  .v131-foot { position: sticky; bottom: calc(-18px - env(safe-area-inset-bottom, 0px)); background: var(--surface); padding: 10px 0 4px; }
  .v131-foot button { flex: 1 1 auto; padding: 0 12px; }
}

/* ---------- Periodic finance report ---------- */
.v131-report .v131-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.v131-report fieldset { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 0; }
.v131-report legend { font-weight: 650; color: var(--ink-2); padding: 0 4px; }
.v131-seg { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 6px; }
.v131-seg label { display: inline-flex; flex-direction: row; align-items: center; gap: 8px; min-height: 42px; padding: 0 14px; margin: 0;
  border: 1px solid var(--line); border-radius: 999px; cursor: pointer; font-size: 14px; color: var(--ink-2); background: var(--surface); }
.v131-seg input[type=radio] { width: 18px; height: 18px; min-height: 0; margin: 0; padding: 0; flex: none; accent-color: var(--brand-2); }
.v131-seg input:checked + span { color: var(--brand); font-weight: 650; }
.v131-seg label:has(input:checked) { border-color: var(--brand-2); background: var(--brand-soft); }
.v131-report .record-actions { align-items: center; }
.v131-report .record-actions button, .v131-report .record-actions a { min-height: 42px; display: inline-flex; align-items: center; }
.v131-report-preview { margin-top: 12px; }
.v131-report-preview img { display: block; width: 100%; max-width: 432px; height: auto; border-radius: 14px; border: 1px solid var(--line); background: #fff; }
.v131-report-status { display: flex; flex-wrap: wrap; gap: 6px 16px; color: var(--muted); font-size: 12px; margin-top: 8px; }
