/* =====================================================================
   입출차 썸네일 PC 저장 (js/thumbSave.js) — 틀은 .pc-backdrop/.pc-dialog 를 같이 쓴다
   ===================================================================== */
.ts-dialog { max-width: 560px; }
.ts-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--border-subtle); font-size: 13px; }
.ts-row-top { align-items: flex-start; }
.ts-k { flex: 0 0 64px; color: var(--text-muted); }
.ts-v { flex: 1 1 auto; min-width: 0; color: var(--text-body); overflow-wrap: anywhere; }
.ts-row .btn-inline { flex: none; min-height: 34px; }
.ts-date, .ts-interval {
  height: 34px; padding: 0 10px; box-sizing: border-box; border: 1px solid var(--border-strong);
  border-radius: 9px; background: var(--surface); color: var(--text); font: inherit; font-size: 13px;
}
.ts-warn { margin: 8px 0 0; font-size: 12.5px; line-height: 1.6; color: var(--warn-text); }
.ts-bad { color: var(--err-text); }
.ts-all { display: flex; align-items: center; gap: 6px; padding-bottom: 6px; font-weight: 700; cursor: pointer; }
.ts-devs { max-height: 240px; overflow-y: auto; }
.ts-dev { display: flex; align-items: center; gap: 8px; min-height: 30px; padding: 3px 0; cursor: pointer; }
.ts-dev input, .ts-all input { width: 16px; height: 16px; margin: 0; accent-color: var(--accent); }
.ts-dev-name { flex: 0 1 auto; min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ts-dev-st { margin-left: auto; flex: none; font-size: 12px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.ts-server { margin: 0 0 8px; padding: 8px 10px; border-radius: 8px; background: var(--surface-sunken); font-size: 12.5px; line-height: 1.6; color: var(--text-body); }
.ts-server:empty { display: none; }
.ts-hint { margin: 10px 0 0; font-size: 12px; line-height: 1.6; color: var(--text-muted); }
.ts-hint code { font-size: 11.5px; padding: 0 4px; border-radius: 4px; background: var(--surface-muted); }
.ts-dialog .pc-msg { min-height: 20px; margin-top: 8px; color: var(--text-body); line-height: 1.55; }
.ts-dialog .pc-actions { align-items: center; }

/* 자동 저장 표시 */
.ts-pill {
  position: fixed; right: 16px; bottom: 16px; z-index: 2500;
  display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px;
  border: 1px solid var(--border-strong); border-radius: 999px; cursor: pointer;
  background: var(--surface); color: var(--text); font-size: 13px; font-weight: 700;
  box-shadow: 0 8px 24px rgba(16, 24, 40, 0.18);
}
.ts-pill-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok-dot, #12B76A); animation: ts-blink 1.6s ease-in-out infinite; }
@keyframes ts-blink { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .ts-pill-dot { animation: none; } }

/* 사진 크게 보기 */
.ts-pv { max-width: 820px; padding: 14px; }
.ts-pv-img {
  display: flex; align-items: center; justify-content: center; min-height: 240px;
  border-radius: 10px; background: #0B0F17; overflow: hidden;
}
.ts-pv-img img { display: block; width: 100%; height: auto; max-height: 70vh; object-fit: contain; }
.ts-pv-wait { padding: 40px 16px; color: #D0D5DD; font-size: 13px; text-align: center; }
.ts-pv-cap { margin-top: 10px; font-size: 13.5px; color: var(--text-body); overflow-wrap: anywhere; }
.ts-pv-cap b { font-size: 15px; color: var(--text); letter-spacing: .3px; }
.ts-pv .pc-msg { color: var(--text-muted); overflow-wrap: anywhere; }
.ts-pv-gap { flex: 1 1 auto; }

@media (max-width: 600px) {
  .ts-pill { right: 12px; bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
  .ts-pv { padding: 12px; }
  .ts-pv-gap { display: none; }
  .ts-dialog .pc-actions .btn-inline, .ts-interval { flex: 1 1 auto; }
}

/* 장비 화면 도구줄의 [썸네일 PC 저장] */
.st-thumbsave { flex: none; height: 36px; min-height: 36px; white-space: nowrap; }
.st-thumbsave[hidden] { display: none; }

/* 설정 › 입출차 사진 (js/screens/entryImageSettings.js) — 틀은 환경 설정의 .pref-* 를 같이 쓴다 */
.eis .pref-switch:disabled { opacity: .45; cursor: not-allowed; }
.eis-muted { color: var(--text-faint); font-weight: 600; }
.eis-bad { color: var(--err-text); }
.eis-disk { flex-shrink: 0; text-align: right; font-size: 12.5px; line-height: 1.6; color: var(--text-body); font-variant-numeric: tabular-nums; }
.eis-msg { min-height: 18px; padding: 6px 0 2px; font-size: 12.5px; color: var(--text-muted); }
.eis-msg:empty { display: none; }
.eis-devbar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 8px 0;
  position: sticky; top: 0; z-index: 2; background: var(--surface);
}
.eis-devbar .btn-inline { min-height: 34px; }
.eis-count { flex: 1 1 auto; min-width: 120px; font-size: 12.5px; font-weight: 700; color: var(--text-muted); }
.eis-devmsg { min-height: 0; font-size: 12.5px; color: var(--text-muted); padding: 0 0 6px; }
.eis-devmsg:empty { display: none; }
.eis-devs { border-top: 1px solid var(--border-subtle); user-select: none; -webkit-user-select: none; touch-action: pan-y; }
.eis-devs.is-dragging { touch-action: none; cursor: grabbing; }
.eis-dev {
  display: flex; align-items: center; gap: 10px; padding: 9px 6px; margin: 0 -6px;
  border-bottom: 1px solid var(--border-subtle); border-radius: 6px; cursor: pointer;
}
.eis-dev:hover { background: var(--surface-sunken); }
.eis-dev.is-changed { background: var(--accent-soft, var(--surface-sunken)); }
.eis-dev.is-locked { cursor: default; }
.eis-dev.is-locked:hover { background: none; }
.eis-check { width: 18px; height: 18px; margin: 0; flex: none; accent-color: var(--accent); pointer-events: none; }
.eis-dev-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.eis-dev-name { font-size: 13px; font-weight: 700; color: var(--text); }
.eis-dev-body small { font-size: 11.5px; color: var(--text-faint); line-height: 1.5; overflow-wrap: anywhere; }
.eis-tag { margin-left: 8px; font-style: normal; font-size: 11px; font-weight: 700; color: var(--accent-ink); }
/* 저장 공간 카드 (2026-12-01) — 디스크 막대 · 범례 · 날짜 지정 삭제 · 월별 표 */
.eis-bar {
  position: relative; display: flex; height: 14px; margin: 4px 0 8px; overflow: visible;
  border-radius: 7px; background: var(--surface-muted); box-shadow: inset 0 0 0 1px var(--border-subtle);
}
.eis-bar > span:first-child { border-radius: 7px 0 0 7px; }
.eis-bar-photo { background: var(--accent); }
.eis-bar-other { background: var(--border-strong); }
.eis-bar-mark { position: absolute; top: -4px; bottom: -4px; width: 2px; margin-left: -1px; background: var(--warn-text); border-radius: 1px; }
.eis-legend { display: flex; flex-wrap: wrap; gap: 4px 16px; padding-bottom: 8px; font-size: 12px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.eis-legend b { color: var(--text); }
.eis-dot { display: inline-block; width: 9px; height: 9px; margin-right: 5px; border-radius: 2px; vertical-align: -1px; }
.eis-dot.photo { background: var(--accent); }
.eis-dot.other { background: var(--border-strong); }
.eis-dot.free { background: var(--surface-muted); box-shadow: inset 0 0 0 1px var(--border); }
.eis-cut-ctl { display: flex; gap: 6px; flex-shrink: 0; }
.eis-cut-ctl input[type="date"] { min-width: 150px; }
.eis-cut-result {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px;
  margin: 4px 0 8px; padding: 8px 12px; border-radius: 8px; font-size: 12.5px;
  background: var(--warn-bg-soft); border: 1px solid var(--warn-bg); color: var(--text-body);
}
.eis-months { width: 100%; margin-top: 10px; border-collapse: collapse; font-size: 12.5px; font-variant-numeric: tabular-nums; }
.eis-months th { text-align: left; font-weight: 700; color: var(--text-muted); padding: 6px 4px; border-bottom: 1px solid var(--border); }
.eis-months td { padding: 6px 4px; border-bottom: 1px solid var(--border-subtle); color: var(--text-body); }
.eis-months th:nth-child(n+3), .eis-months td:nth-child(n+3) { text-align: right; }
@media (max-width: 600px) {
  .eis-dev { padding: 12px 6px; }
  .eis-count { order: -1; flex-basis: 100%; }
  .eis-cut, .eis-photo-row { flex-wrap: wrap; }
  .eis-photo-row .eis-disk { width: 100%; text-align: left; }
  .eis-cut-ctl { width: 100%; }
  .eis-cut-ctl input[type="date"] { flex: 1 1 auto; }
}

/* QR 창 위쪽 '결제 받기' 띠 (qrModal.js) */
.qrm-pay {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 0 0 12px; padding: 10px 12px; border-radius: 10px;
  border: 1px solid var(--border); background: var(--surface-sunken);
}
.qrm-pay.on { border-color: var(--ok-border, var(--border)); background: var(--ok-bg); }
.qrm-pay-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.qrm-pay-text b { font-size: 13.5px; color: var(--text); }
.qrm-pay-text small { font-size: 12px; color: var(--text-muted); line-height: 1.5; }
.qrm-pay .pref-switch { flex: none; }

/* =====================================================================
   결제 › QR · 요금 설정: 주차장 카드(상자) 격자 + 일괄 적용 줄 (2026-11-30, 표 → 카드)
   payments.js renderQr · parkingSettings.js renderList
   ===================================================================== */
.pk-boxes { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.pk-box {
  display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 12px 14px;
  border: 1px solid var(--border); border-radius: 12px; background: var(--surface);
}
.pk-box.is-on { border-color: var(--ok-border, var(--border)); }
.pk-box.is-picked { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-ring, transparent); }
.pk-box-top { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pk-box-pick { display: inline-flex; align-items: center; flex: none; cursor: pointer; }
.pk-box-pick input { width: 17px; height: 17px; margin: 0; accent-color: var(--accent); }
.pk-box-name {
  flex: 1 1 auto; min-width: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 2px 6px;
  font-size: 14px; font-weight: 800; color: var(--text); text-decoration: none; overflow-wrap: anywhere;
}
a.pk-box-name:hover { color: var(--accent-ink); }
.pk-box-name small { flex-basis: 100%; font-size: 11.5px; font-weight: 600; color: var(--text-faint); }
.pk-box-top .pref-switch { flex: none; }
.pk-box-state { flex: none; font-size: 11.5px; font-weight: 700; color: var(--text-faint); }
.pk-box-state.on { color: var(--ok-text); }
.pk-box-fee { font-size: 13px; font-weight: 700; color: var(--text-body); }
.pk-box-meta { font-size: 12px; color: var(--text-muted); line-height: 1.5; }
.pk-box-go { align-self: flex-start; margin-top: 2px; font-size: 12.5px; font-weight: 700; color: var(--accent-ink); text-decoration: none; }
.pk-box-btn { align-self: flex-start; margin-top: 2px; min-height: 32px; }

.pk-bulk {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 8px; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: 12px; background: var(--surface);
  position: sticky; top: 0; z-index: 3;
}
.pk-bulk-n { flex: 1 1 auto; font-size: 12.5px; font-weight: 700; color: var(--text-muted); }
.pk-bulk-btns { display: flex; flex-wrap: wrap; gap: 6px; }
.pk-bulk-btns .btn-inline { min-height: 34px; }
.pk-bulk-msg { margin: 0 0 10px; font-size: 12.5px; color: var(--text-body); line-height: 1.6; }
.pk-bulk-msg:empty { display: none; }
.pk-bulk-fails { margin: 4px 0 0; padding-left: 18px; color: var(--err-text); }

.pk-defaults { margin: 0 0 12px; padding: 12px 16px; }
.pk-defaults > summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; cursor: pointer; list-style: none; }
.pk-defaults > summary::-webkit-details-marker { display: none; }
.pk-defaults > summary::before { content: '▸'; color: var(--text-faint); }
.pk-defaults[open] > summary::before { content: '▾'; }
.pk-def-title { font-size: 14px; font-weight: 800; color: var(--text); }
.pk-def-sum { font-size: 12.5px; color: var(--text-muted); }
.pk-defaults .pk-form { margin-top: 8px; }

/* 장비 상세 머리의 '웹할인 결제' 스위치 */
.dt-pay { display: inline-flex; align-items: center; gap: 8px; margin-right: 4px; }
.dt-pay:empty { display: none; }
.dt-pay-label { font-size: 12.5px; font-weight: 700; color: var(--text-muted); white-space: nowrap; }
.dt-pay-label.on { color: var(--ok-text); }
.dt-pay .pref-switch:disabled { opacity: .45; cursor: not-allowed; }

@media (max-width: 600px) {
  .pk-boxes { grid-template-columns: 1fr; }
  .pk-bulk { top: 0; }
  .pk-bulk-btns { width: 100%; }
  .pk-bulk-btns .btn-inline { flex: 1 1 auto; }
}

/* 결제 › 요금 설정: PC 에서 화면 끝까지 늘어나지 않게 필요한 만큼만 쓴다 (왼쪽 정렬)
   목록은 카드 3칸(약 300px)이 들어가는 폭, 상세 입력 화면은 입력칸이 읽기 좋은 폭 */
/* QR 탭도 같은 폭 (payments.js render 가 두 탭에 .pay-body-narrow 를 붙인다) */
.pay-body-narrow { max-width: 980px; }
#payments-body .pk-list,
#payments-body .pk-back { max-width: 760px; }
