/* FileShare UI · css/features.css · Details tabs, tags, notes, sharing and other workspace features. Loaded in the order listed in index.html. */
/* ---------------------------------------------------------------- Phase 1 additions */
.ic-wrap { position: relative; display: inline-grid; }
.badge { position: absolute; top: -6px; right: -10px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--c-red); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.top-action.has-menu span:last-child { white-space: nowrap; }

.menu { position: fixed; z-index: 70; min-width: 210px; background: #fff; border: 1px solid var(--line); border-radius: 6px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .14); padding: 6px; display: grid; }
.menu button { text-align: left; border: 0; background: none; padding: 8px 12px; border-radius: 4px; cursor: pointer; color: var(--ink); font-size: 14px; }
.menu button:hover { background: var(--hover); }
.menu button:disabled { color: #A7B0B9; cursor: default; background: none; }
.menu .mi { display: flex; align-items: center; gap: 10px; }
.menu .mi .ic { width: 18px; height: 18px; }
.menu .mi kbd { margin-left: auto; font: inherit; font-size: 12px; color: var(--muted); }
.menu-title { padding: 6px 12px 4px; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 260px; }
.tool-wide { width: auto; padding: 0 10px; gap: 6px; display: inline-flex; align-items: center; font-weight: 500; color: var(--ink); }
.toolbar-hint { margin-left: 10px; font-size: 12.5px; color: var(--muted); }
.clip-chip { margin-left: auto; font-size: 12.5px; background: var(--select-soft); border: 1px solid #EADB70; border-radius: 12px; padding: 2px 6px 2px 10px; display: inline-flex; align-items: center; gap: 6px; }
.clip-chip button { border: 0; background: none; cursor: pointer; color: var(--muted); font-size: 14px; padding: 0 4px; }
.trow.cut, tr.cut td { opacity: .5; }
.menu hr { border: 0; border-top: 1px solid var(--line-soft); margin: 4px 0; }

.search-panel { overflow-y: auto; }
.adv-search { display: grid; gap: 10px; }
.adv-search select, .dialog select, .details-body select { font: inherit; padding: 7px 8px; border: 1px solid var(--line); border-radius: 4px; background: #fff; color: var(--ink); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.two input { width: 100%; }
.check { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: #3E4C59; }
.check input { width: 16px; height: 16px; accent-color: var(--brand); }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.side-title { margin: 18px 0 6px; font-size: 13.5px; font-weight: 500; color: var(--muted); }
.saved-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.saved-list li { display: flex; align-items: center; gap: 6px; }
.saved-list button.run { flex: 1; text-align: left; border: 0; background: none; padding: 6px 8px; border-radius: 4px; cursor: pointer; color: var(--c-blue); }
.saved-list button.run:hover { background: var(--hover); }
.saved-list .muted { padding: 6px 8px; font-size: 13px; }

.grid th.sortable { cursor: pointer; user-select: none; }
.grid th.sortable:hover { background: #DCE2E7; }
.grid th .arrow { color: var(--brand); margin-left: 4px; }
.grid .state { width: 22px; }
.grid .state .ic { width: 16px; height: 16px; }
.pill { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 12px; font-weight: 500; }
.pill-lock { background: #FDE8D7; color: #8A4B12; }
.pill-out { background: #E3EDF8; color: #1F3D5E; }
.pill-yes { background: #E3F4EC; color: #155E3E; }
.pill-no { background: var(--line-soft); color: var(--muted); }
.unread td { font-weight: 500; }
.unread td:first-child::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--c-blue); margin-right: 6px; }

.stars { display: inline-flex; gap: 2px; }
.stars button { border: 0; background: none; padding: 0 1px; font-size: 20px; line-height: 1; cursor: pointer; color: #D0D6DC; }
.stars button.on { color: #F2B84B; }
.stars-meta { margin-left: 8px; color: var(--muted); font-size: 12.5px; }

.tagbox { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 6px; border: 1px solid var(--line); border-radius: 4px; background: #fff; max-width: 620px; }
.tagchip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 4px 2px 10px; border-radius: 12px; background: var(--select-soft); font-size: 13px; }
.tagchip button { border: 0; background: none; cursor: pointer; color: var(--muted); font-size: 14px; line-height: 1; padding: 0 4px; }
.tagbox input { border: 0; flex: 1; min-width: 120px; padding: 4px; }
.tagbox input:focus { box-shadow: none; }
.tagcloud { display: flex; flex-wrap: wrap; gap: 10px 14px; padding: 18px; align-items: baseline; }
.tagcloud button { border: 0; background: none; cursor: pointer; color: var(--brand); padding: 0; }
.tagcloud button:hover { text-decoration: underline; }

.note-list { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; max-width: 680px; }
.note-list li { background: #FFFBEA; border: 1px solid #F1E6B2; border-radius: 4px; padding: 8px 12px; }
.note-meta { display: flex; justify-content: space-between; gap: 8px; font-size: 12.5px; color: var(--muted); margin-bottom: 4px; }
.note-text { white-space: pre-wrap; word-break: break-word; }
textarea { font: inherit; padding: 8px 10px; border: 1px solid var(--line); border-radius: 4px; width: 100%; max-width: 680px; min-height: 70px; resize: vertical; }

.perm-table { border-collapse: collapse; font-size: 13px; }
.perm-table th, .perm-table td { border: 1px solid var(--line); padding: 5px 6px; text-align: center; }
.perm-table th { background: var(--grid-head); font-weight: 500; white-space: nowrap; }
.perm-table td:first-child, .perm-table th:first-child { text-align: left; white-space: nowrap; }
.perm-wrap { overflow-x: auto; max-width: 100%; }
.dialog-xl { width: min(980px, 96vw); }
.dialog-lg { width: min(680px, 94vw); }
.field-rows { display: grid; gap: 6px; }
.field-row { display: grid; grid-template-columns: 1.4fr 110px 90px 1.4fr auto; gap: 6px; align-items: center; }
.pick-tree { max-height: 340px; overflow: auto; border: 1px solid var(--line); border-radius: 4px; padding: 6px; }
.pick-tree .trow.selected { background: var(--select); }
.result-box { background: #F4F6F8; border: 1px solid var(--line); border-radius: 4px; padding: 10px; word-break: break-all; font-size: 13px; }
.view-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line-soft); background: #fff; position: sticky; top: 0; z-index: 2; }
.view-head h2 { margin: 0; font-size: 16px; font-weight: 500; flex: 1; }
