/* b35: attachments. A file or a link to the company's own storage, removable with a note. */

.att-in { display: flex; flex-direction: column; gap: 6px; min-width: 0; max-width: 100%; }
.att-file { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; margin: 0; font-size: 12px; font-weight: 600; color: var(--ink, #1B2537); cursor: pointer; }
.att-file input[type=file] { max-width: 240px; font-size: 11.5px; }
.att-req { color: #B23B2E; font-weight: 600; }

.att-link > summary { list-style: none; display: inline-flex; align-items: center; min-height: 28px; cursor: pointer;
  font-size: 12px; color: var(--navy-700, #16305E); text-decoration: underline; text-underline-offset: 2px; }
.att-link > summary::-webkit-details-marker { display: none; }
.att-link[open] > summary { margin-bottom: 4px; }
.att-link-h { font-size: 12px; font-weight: 600; margin-bottom: 4px; }
.att-link-rows { display: flex; flex-direction: column; gap: 6px; }
.att-link-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 6px; }
.att-link-row input { font-size: 12px; min-width: 0; }
.att-add { align-self: flex-start; margin-top: 4px; padding: 0 2px; min-height: 28px; border: 0; background: none;
  font-size: 12px; color: var(--navy-700, #16305E); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.att-note { margin: 4px 0 0; font-size: 11px; color: var(--muted, #56647A); text-wrap: pretty; }
.att-err { display: block; margin: 4px 0 0; font-size: 11.5px; color: #B23B2E; }

.att-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.att-item { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 4px; max-width: 100%; }
.att-item:has(> .att-rm[open]) { flex-basis: 100%; }
.att-chip { display: inline-flex; align-items: center; gap: 5px; min-height: 28px; max-width: 100%; padding: 2px 9px;
  border-radius: 6px; border: 1px solid #D5DCE6; background: #FBFCFE; color: #16305E; font-size: 11.5px;
  text-decoration: none; transition-property: background-color, border-color; transition-duration: .15s; }
.att-chip:hover { background: #F1F4F9; border-color: #B9C4D4; color: #0E1F3D; }
.att-chip .att-nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.att-chip.is-link { border-style: dashed; }
.att-host { font-size: 10.5px; color: #56647A; padding-left: 5px; border-left: 1px solid #D5DCE6; white-space: nowrap; }
.att-flag { font-size: 10.5px; color: #7A4B00; background: #FFF4DE; border: 1px solid #F1D49B; border-radius: 6px; padding: 1px 6px; cursor: help; }

.att-rm > summary { list-style: none; display: inline-flex; align-items: center; justify-content: center; position: relative;
  width: 24px; height: 24px; border-radius: 6px; color: #56647A; font-size: 15px; line-height: 1; cursor: pointer; }
.att-rm > summary::-webkit-details-marker { display: none; }
.att-rm > summary::after { content: ""; position: absolute; inset: -8px; }
.att-rm > summary:hover { background: #F1F4F9; color: #B23B2E; }
.att-rm[open] { flex-basis: 100%; }
.att-rm form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 6px 10px; margin: 6px 0 2px; padding: 10px 12px;
  border-radius: 8px; background: var(--bg, #F4F6FA); }
.att-rm label { display: flex; flex-direction: column; gap: 3px; flex: 1 1 240px; margin: 0; font-size: 11.5px; font-weight: 600; }
.att-rm .att-note { flex-basis: 100%; margin: 0; }

.att-removed { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-direction: column; gap: 3px; }
.att-removed li { font-size: 11.5px; color: #56647A; text-wrap: pretty; }
.att-removed s { color: #6B778A; }
.att-removed q { color: #2B3A52; }

@media (max-width: 560px) {
  .att-link-row { grid-template-columns: 1fr; }
  .att-file input[type=file] { max-width: 100%; }
}
@media (pointer: coarse) {
  .att-chip, .att-add, .att-link > summary { min-height: 40px; }
  .att-rm > summary { width: 40px; height: 40px; }
}

/* Config: Attachments page */
  .cfg-att-modes { display:flex; flex-direction:column; gap:6px; }
  .cfg-att-mode, .cfg-att-kind { display:flex; align-items:flex-start; gap:10px; margin:0; padding:8px 10px; min-height:40px; border-radius:8px; border:1px solid #E1E6EE; cursor:pointer; font-size:13px; }
  .cfg-att-mode:has(input:checked), .cfg-att-kind:has(input:checked) { background:#F1F4F9; border-color:#B9C4D4; }
  .cfg-att-mode input, .cfg-att-kind input { margin-top:3px; }
  .cfg-att-kinds { display:grid; grid-template-columns:repeat(auto-fit, minmax(260px, 1fr)); gap:8px; }
  .cfg-att-kind > span { display:flex; flex-direction:column; gap:2px; }
  .cfg-att-kind .cfg-mute { font-size:11.5px; text-wrap:pretty; }
  .cfg-att-hosts { display:flex; flex-direction:column; gap:6px; margin:0; max-width:560px; }
  .cfg-att-body { padding: 12px 18px 16px; }
  .cfg-att-body > p.cfg-mute:first-child { margin-top: 0; }
