/* win-add.css: Add contact window and its event and menu pop-ups.
   Every colour comes from tokens.css (no literals here). Dark mode lives in tokens.css only. */
.ac-in { position: relative; }
.ac .ac-in input, .ac .ac-in select { margin: 0; display: block; }
.ac-in input { padding-right: 150px; }
.ac-note { position: absolute; right: 10px; top: 0; bottom: 0; margin: 0; display: flex; align-items: center; max-width: 140px; font-size: 12.5px; color: var(--bd-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
.ac-note.ok { color: var(--bd-green); }
.ac-note.warn { color: var(--bd-burg); }
.ac-open { margin-left: 8px; border: 0; background: none; padding: 0; font: inherit; text-decoration: underline; cursor: pointer; color: var(--bd-ink); }
.ac-scan { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 24px; }
.ac-shot { position: relative; height: 300px; background: var(--shot-bg); display: grid; place-items: center; overflow: hidden; }
.ac-shot video, .ac-shot img { width: 100%; height: 100%; object-fit: contain; display: block; }
.ac-empty { max-width: 300px; padding: 0 20px; text-align: center; font-size: 14px; color: var(--on-dark-text); }
.ac-badge { position: absolute; left: 12px; top: 12px; padding: 2px 8px; background: var(--on-photo); color: var(--bd-ink); font-size: 12px; }
.ac-shotb { position: absolute; right: 12px; bottom: 12px; display: flex; gap: 8px; }
.ac-shotb button { height: 32px; display: inline-flex; align-items: center; gap: 6px; padding: 0 10px; border: 0; background: var(--on-photo); color: var(--bd-ink); font: 500 13px var(--sans); cursor: pointer; }
.ac-src { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.ac-src button { height: 52px; display: flex; align-items: center; gap: 10px; padding: 0 12px; border: 1px solid var(--bd-line2); background: var(--bd-paper); color: var(--bd-ink); font: 500 13.5px var(--sans); text-align: left; cursor: pointer; }
.ac-src button:hover, .ac-src button.on { border-color: var(--bd-ink); }
.ac-ev { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; padding: 10px 12px; background: var(--bd-rail); }
.ac-ev > span { flex: 1; min-width: 0; }
.ac-evk { display: block; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--bd-muted); }
.ac-evn { font-weight: 500; color: var(--bd-ink); }
.ac-evn.none { color: var(--bd-muted); font-weight: 400; }
.ac-evn[hidden] { display: none; }
.ac #acEvIn { height: 34px; margin-top: 4px; }
#acEvCh { border: 0; background: none; padding: 0; font: 13px var(--sans); text-decoration: underline; color: var(--bd-ink); cursor: pointer; }
.ac-r .bd-cap { margin: 0 0 8px; }
.ac-r .ac-tcap { margin-top: 18px; }
.ac-trow { display: flex; width: 100%; justify-content: space-between; gap: 12px; padding: 9px 0; border: 0; border-top: 1px solid var(--bd-line2); background: none; font: 14px var(--sans); text-align: left; cursor: pointer; }
.ac-trow b { font-weight: 500; color: var(--bd-ink); }
.ac-tf, .ac-tt { color: var(--bd-muted); }
.ac-tt { font-size: 13px; }
.ac-tnone { margin: 0; padding: 9px 0; border-top: 1px solid var(--bd-line2); font-size: 14px; color: var(--bd-muted); }
.ac-done { padding: 30px 0 10px; }
.ac-dk { font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--bd-green); }
.ac-dn { margin-top: 6px; font: 400 26px/1.2 var(--serif); color: var(--bd-ink); }
.ac-ds { margin-top: 2px; color: var(--bd-muted); }
.ac-db { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
@media (max-width: 1024px) {
  .ac-scan { grid-template-columns: minmax(0, 1fr); gap: 14px; display: flex; flex-direction: column; }
  .ac-shot { height: 230px; }
  .ac-r { display: flex; flex-direction: column; order: 2; }
  .ac-l { display: contents; }
  .ac-ev { order: 3; }
}
@media (max-width: 640px) {
  .ac-src button { gap: 6px; padding: 0 8px; }
  .ac-btns #acSave { flex: 1.7; }
  .ac-in input { padding-right: 110px; }
  .ac-note { max-width: 100px; }
}
.ac-in.btn-in input { padding-right: 110px; }
.ac-inbtn { position: absolute; right: 5px; top: 5px; height: 30px; padding: 0 10px; border: 1px solid var(--bd-line2); background: var(--bd-paper); color: var(--bd-ink); font: 500 13px var(--sans); cursor: pointer; white-space: nowrap; }
.ac-inbtn:hover { border-color: var(--bd-ink); }
.ac-in.unit input { padding-right: 96px; }
.ac-lock { padding: 10px 12px; background: var(--bd-rail); font-size: 13.5px; color: var(--bd-ink); }
.ac-del { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0; border: 0; background: none; color: var(--bd-burg); font: 500 13.5px var(--sans); cursor: pointer; white-space: nowrap; }
.ac-del:hover { text-decoration: underline; }
.ac-del[data-sure="1"], .ac-del[data-arm="1"] { font-weight: 600; }
@media (max-width: 640px) {
  .ac-wrap .ac-fl:has(.ac-del:not([hidden])) { width: 100%; }
}
.ac-fl:has(.ac-del:not([hidden])) .ac-fn { display: none; }
@media (max-width: 640px) {
  #acAddWrap .ac { height: auto; align-self: end; max-height: calc(100dvh - 54px); }
}
