/* Cardin 화면. 휴대폰 세로 화면 기준, 넓은 화면에서는 가운데 한 줄로 */
:root {
  --bg: #0b111c;
  --bg-top: rgba(11, 17, 28, .92);
  --card: #151e2e;
  --card2: #1c2739;
  --line: rgba(255, 255, 255, .075);
  --ink: #eef2f8;
  --sub: #a3aec0;
  --sub2: #758199;
  --accent: #2f6fff;
  --accent-hi: #8fb0ff;
  --danger: #ff6b6b;
  --ok: #43d69a;
  --radius: 16px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --w: 560px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
/* 연타·두 번 탭으로 화면이 커지지 않게 */
button, a, label, input, .row, .fab, .dial-item { touch-action: manipulation; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; -webkit-tap-highlight-color: transparent; }
button, .row, .fab, .dial-item, .bar-btn { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
[hidden] { display: none !important; }
.ic { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* ---------- 시작·잠금·오류 화면 ---------- */
.screen { min-height: 100vh; min-height: 100dvh; padding: calc(24px + var(--safe-t)) 24px calc(24px + var(--safe-b)); }
.screen.center { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.brand { display: flex; align-items: center; gap: 12px; font-weight: 750; letter-spacing: -.02em; }
.brand.lg { font-size: 26px; flex-direction: column; gap: 14px; margin-bottom: 28px; }
.brand-ic { width: 56px; height: 56px; border-radius: 14px; display: block; }
.load-bar { width: min(260px, 70vw); height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .08); overflow: hidden; margin-bottom: 22px; }
.load-bar i { display: block; height: 100%; width: 40%; background: linear-gradient(90deg, transparent, var(--accent), transparent); animation: sweep 1.3s ease-in-out infinite; }
@keyframes sweep { from { transform: translateX(-100%); } to { transform: translateX(250%); } }
.steps { list-style: none; margin: 0; padding: 0; width: min(260px, 74vw); text-align: left; }
.steps li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 7px 0 7px 22px; position: relative; color: var(--sub2); font-size: 14px; }
.steps li::before { content: ""; position: absolute; left: 4px; top: 50%; width: 7px; height: 7px; margin-top: -3.5px; border-radius: 50%; background: rgba(255, 255, 255, .16); }
.steps li.on { color: var(--ink); }
.steps li.on::before { background: var(--accent); box-shadow: 0 0 0 0 rgba(47, 111, 255, .6); animation: pulse 1.2s infinite; }
.steps li.done { color: var(--sub); }
.steps li.done::before { background: var(--ok); }
.steps li.fail { color: var(--danger); }
.steps li.fail::before { background: var(--danger); }
.steps em { font-style: normal; font-variant-numeric: tabular-nums; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 12.5px; color: var(--sub2); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(47, 111, 255, .55); } 100% { box-shadow: 0 0 0 9px rgba(47, 111, 255, 0); } }
.load-note { min-height: 20px; margin: 16px 0 0; font-size: 13px; color: var(--sub2); }

.login { width: min(320px, 100%); display: flex; flex-direction: column; align-items: stretch; }
.login .brand { align-self: center; }
.lead { margin: 0 0 14px; color: var(--sub); font-size: 15px; }
.inp { width: 100%; height: 52px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); color: var(--ink); padding: 0 16px; font: inherit; font-size: 17px; outline: none; }
.inp:focus { border-color: var(--accent); }
.hint { min-height: 22px; margin: 8px 2px 10px; font-size: 13.5px; text-align: left; }
.hint.err { color: var(--danger); }
.btn { height: 50px; border-radius: 14px; padding: 0 20px; font-weight: 650; font-size: 16px; background: var(--card2); color: var(--ink); }
.btn.pri { background: var(--accent); color: #fff; }
.btn.danger { background: rgba(255, 107, 107, .14); color: var(--danger); }
.btn:disabled { opacity: .55; }
.err-msg { margin: 0 0 6px; font-size: 17px; font-weight: 600; }
.err-code { margin: 0 0 22px; color: var(--sub2); font-size: 13px; font-variant-numeric: tabular-nums; }
#v-error .btn { min-width: 160px; }

/* ---------- 목록 ---------- */
#v-app { min-height: 100vh; min-height: 100dvh; padding-bottom: calc(110px + var(--safe-b)); }
.quiet { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 30; overflow: hidden; }
.quiet i { display: block; height: 100%; width: 35%; background: var(--accent); animation: sweep 1.1s ease-in-out infinite; }
.top { position: sticky; top: 0; z-index: 10; background: var(--bg-top); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); padding: calc(14px + var(--safe-t)) 16px 12px; }
.top-row, .search, .list-wrap, .banner { max-width: var(--w); margin-left: auto; margin-right: auto; }
.top-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 4px 4px 12px; }
.title { margin: 0; font-size: 28px; font-weight: 780; letter-spacing: -.03em; }
.count { color: var(--sub); font-size: 14px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.search { display: flex; align-items: center; gap: 8px; height: 46px; padding: 0 6px 0 14px; border-radius: 14px; background: var(--card); color: var(--sub2); }
.search input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: none; color: var(--ink); font: inherit; font-size: 16px; }
.search input::placeholder { color: var(--sub2); }
.search input::-webkit-search-cancel-button { display: none; }
.clear { width: 36px; height: 36px; display: grid; place-items: center; color: var(--sub2); border-radius: 10px; }
.clear .ic { width: 18px; height: 18px; }
.banner { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 4px; margin-bottom: 4px; padding: 10px 12px 10px 14px; border-radius: 12px; background: rgba(255, 107, 107, .12); color: #ffb3b3; font-size: 13.5px; }
.banner button { flex: none; color: #fff; font-weight: 650; font-size: 13.5px; padding: 6px 10px; border-radius: 9px; background: rgba(255, 107, 107, .22); }
.list-wrap { padding: 6px 16px 0; }
.list { list-style: none; margin: 0; padding: 0; }
.list li + li { margin-top: 8px; }
.row { width: 100%; display: flex; align-items: center; gap: 14px; padding: 10px; border-radius: var(--radius); background: var(--card); text-align: left; transition: background .15s, transform .12s; }
.row:active { background: var(--card2); transform: scale(.985); }
.thumb { flex: none; width: 108px; aspect-ratio: 9 / 5; border-radius: 7px; overflow: hidden; background: #e9ecf1; box-shadow: 0 1px 0 rgba(255, 255, 255, .06), 0 4px 14px rgba(0, 0, 0, .35); position: relative; }
.thumb.ph { background: linear-gradient(110deg, #222d40 30%, #2a3650 50%, #222d40 70%); background-size: 220% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { from { background-position: 120% 0; } to { background-position: -120% 0; } }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb.tall img { object-fit: contain; background: #2a3448; }
.meta-col { flex: 1; min-width: 0; }
.r-name { display: flex; align-items: baseline; gap: 6px; min-width: 0; }
/* 이름은 줄이지 않고 직함 쪽을 줄인다(아주 긴 영문 이름만 줄임) */
.r-name b { flex: 0 0 auto; max-width: 72%; font-size: 17px; font-weight: 700; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.r-name b.dim { color: var(--sub2); font-weight: 600; }
.r-name small { flex: 1 1 0; color: var(--sub); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.r-co { display: block; margin-top: 3px; color: var(--sub); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.empty { text-align: center; padding: 64px 12px 0; color: var(--sub); }
.empty-card { width: 150px; aspect-ratio: 9 / 5; margin: 0 auto 22px; border-radius: 12px; border: 1.5px dashed rgba(255, 255, 255, .2); display: grid; place-items: center; color: var(--sub2); }
.empty-card .ic { width: 30px; height: 30px; }
.empty-t { margin: 0 0 6px; color: var(--ink); font-size: 17px; font-weight: 650; }
.empty-s { margin: 0; font-size: 14.5px; line-height: 1.6; }
.empty-s b { color: var(--ink); font-weight: 650; }
.none { text-align: center; color: var(--sub); padding: 48px 0; margin: 0; }
/* ---------- 명함 보기(오른쪽에서 들어오는 장) ---------- */
.sheet {
  position: fixed; inset: 0; z-index: 40; background: var(--bg); display: flex; flex-direction: column;
  transform: translateX(100%); transition: transform .28s cubic-bezier(.2, .8, .2, 1);
}
.sheet.in { transform: none; }
.bar { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 8px; height: calc(54px + var(--safe-t)); padding: var(--safe-t) 8px 0; border-bottom: 1px solid var(--line); background: var(--bg-top); }
.bar-title { flex: 1; min-width: 0; text-align: center; font-weight: 650; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-btn { display: flex; align-items: center; gap: 2px; height: 44px; padding: 0 10px; border-radius: 10px; font-size: 16px; color: var(--accent-hi); flex: none; min-width: 70px; }
.bar-btn.act { justify-content: flex-end; font-weight: 650; }
.bar-btn:disabled { opacity: .45; }
.bar-btn .ic { width: 24px; height: 24px; }
.sheet-body { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; padding: 18px 16px calc(40px + var(--safe-b)); }
.sheet-body > * { max-width: var(--w); margin-left: auto; margin-right: auto; }
.card-img { margin: 0 auto 22px; border-radius: 12px; overflow: hidden; background: #1f2a3d; box-shadow: 0 2px 0 rgba(255, 255, 255, .05), 0 18px 40px rgba(0, 0, 0, .45); }
.card-img img { display: block; width: 100%; height: auto; }
.card-img.tall { max-width: min(330px, 70%); }
.card-img.loading img { filter: blur(6px); transform: scale(1.04); }
.who { padding: 0 4px 16px; }
.who-name { margin: 0; font-size: 27px; font-weight: 780; letter-spacing: -.025em; word-break: keep-all; overflow-wrap: anywhere; }
.who-name.dim { color: var(--sub2); font-size: 22px; font-weight: 650; }
.who-role { margin: 6px 0 0; color: var(--sub); font-size: 15.5px; word-break: keep-all; overflow-wrap: anywhere; }
.who-co { margin: 2px 0 0; color: var(--ink); font-size: 16px; font-weight: 600; word-break: keep-all; overflow-wrap: anywhere; }
.info { margin: 0; border-radius: var(--radius); background: var(--card); overflow: hidden; }
.info > div { display: grid; grid-template-columns: 64px 1fr; gap: 10px; padding: 14px 16px; }
.info > div + div { border-top: 1px solid var(--line); }
.info dt { color: var(--sub2); font-size: 14px; padding-top: 1px; }
.info dd { margin: 0; font-size: 16px; word-break: keep-all; overflow-wrap: anywhere; -webkit-user-select: text; user-select: text; font-variant-numeric: tabular-nums; }
.info.empty-info { padding: 16px; color: var(--sub); font-size: 14.5px; }
.meta { margin: 14px 4px 0; color: var(--sub2); font-size: 13px; }
.del { display: block; margin: 28px auto 0; padding: 12px 18px; color: var(--danger); font-size: 15px; border-radius: 12px; }

/* 고치기 */
.form { display: block; }
.fld { display: block; margin-bottom: 12px; }
.fld span { display: block; margin: 0 2px 6px; color: var(--sub); font-size: 13.5px; }
.fld input, .fld textarea { width: 100%; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--ink); padding: 12px 14px; font: inherit; font-size: 16px; outline: none; }
.fld input { height: 48px; }
.fld textarea { min-height: 76px; resize: vertical; line-height: 1.45; }
.fld input:focus, .fld textarea:focus { border-color: var(--accent); }
.raw { margin-top: 20px; }
.raw h3 { margin: 0 2px 8px; font-size: 13.5px; font-weight: 600; color: var(--sub); }
.raw pre { margin: 0; padding: 12px 14px; border-radius: 12px; background: rgba(255, 255, 255, .04); color: var(--sub); font: inherit; font-size: 14px; white-space: pre-wrap; word-break: break-all; -webkit-user-select: text; user-select: text; }

/* ---------- 저장 진행 창 ---------- */
.overlay { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 20px; background: rgba(4, 8, 15, .72); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); opacity: 0; transition: opacity .2s; }
.overlay.in { opacity: 1; }
.cap-panel { width: min(380px, 100%); border-radius: 20px; background: var(--card); padding: 18px 18px 20px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.cap-pic { position: relative; border-radius: 10px; overflow: hidden; background: #1f2a3d; aspect-ratio: 9 / 5; display: grid; place-items: center; margin-bottom: 16px; }
.cap-pic img { width: 100%; height: 100%; object-fit: contain; display: block; }
.cap-pic.ph { background: linear-gradient(110deg, #222d40 30%, #2a3650 50%, #222d40 70%); background-size: 220% 100%; animation: shimmer 1.4s linear infinite; }
.cap-tag { display: block; margin: -8px 0 12px; font-size: 13px; color: var(--sub); text-align: center; }
.cap-steps { width: 100%; }
.cap-say { min-height: 20px; margin: 10px 0 0; color: var(--sub); font-size: 13.5px; }
.cap-err { margin-top: 12px; }
.cap-err-msg { margin: 0 0 14px; color: var(--danger); font-size: 14.5px; }
.cap-btns, .dlg-btns { display: flex; gap: 10px; }
.cap-btns .btn, .dlg-btns .btn { flex: 1; }
.dlg { width: min(340px, 100%); border-radius: 20px; background: var(--card); padding: 22px 18px 18px; text-align: center; }
.dlg-t { margin: 0 0 6px; font-size: 18px; font-weight: 700; }
.dlg-s { margin: 0 0 20px; color: var(--sub); font-size: 14.5px; }

.toast {
  position: fixed; z-index: 80; left: 50%; bottom: calc(96px + var(--safe-b)); transform: translate(-50%, 16px);
  max-width: min(420px, calc(100vw - 32px)); padding: 12px 16px; border-radius: 14px; background: #2a3650; color: #fff;
  font-size: 14.5px; line-height: 1.45; text-align: center; box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
.toast.on { opacity: 1; transform: translate(-50%, 0); }
.toast.bad { background: #5a2a32; }

@media (min-width: 720px) {
  .title { font-size: 30px; }
  .thumb { width: 124px; }
}
@media (max-width: 360px) {
  .thumb { width: 92px; }
  .row { gap: 12px; }
  .r-name b { font-size: 16px; }
  .info > div { grid-template-columns: 62px 1fr; padding: 13px 14px; }
}

/* ---------- + 단추와 펼침(오른쪽 아래, 엄지가 닿는 자리) ---------- */
.fab-wrap { position: fixed; z-index: 26; right: calc(18px + env(safe-area-inset-right, 0px)); bottom: calc(22px + var(--safe-b)); display: flex; flex-direction: column; align-items: flex-end; }
.fab { width: 60px; height: 60px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; box-shadow: 0 10px 26px rgba(47, 111, 255, .36), 0 2px 8px rgba(0, 0, 0, .4); transition: transform .18s ease; }
.fab .ic { width: 28px; height: 28px; stroke-width: 2; transition: transform .2s ease; }
.fab:active { transform: scale(.94); }
.fab[aria-expanded="true"] .ic { transform: rotate(45deg); }
.dial { display: flex; flex-direction: column; align-items: flex-end; gap: 14px; margin-bottom: 16px; margin-right: 4px; }
.dial-item { display: flex; align-items: center; gap: 12px; opacity: 0; transform: translateY(12px) scale(.9); transition: opacity .18s ease, transform .2s cubic-bezier(.2, .8, .2, 1); }
.dial.in .dial-item { opacity: 1; transform: none; }
.dial.in .dial-item.far { transition-delay: .04s; }
/* 먼 쪽(일괄 업로드)은 엄지 호를 따라 조금 더 왼쪽 위 */
.dial-item.far { margin-right: 26px; }
.dial-label { padding: 8px 12px; border-radius: 10px; background: var(--card2); color: var(--ink); font-size: 15px; font-weight: 600; white-space: nowrap; box-shadow: 0 6px 18px rgba(0, 0, 0, .35); }
.dial-btn { width: 52px; height: 52px; border-radius: 50%; background: #fff; color: #0b111c; display: grid; place-items: center; box-shadow: 0 6px 18px rgba(0, 0, 0, .4); }
.dial-btn .ic { width: 25px; height: 25px; }
.dial-dim { position: fixed; inset: 0; z-index: 25; background: rgba(4, 8, 15, .55); opacity: 0; transition: opacity .18s; }
.dial-dim.in { opacity: 1; }

/* ---------- 고르기(여러 장 지우기) ---------- */
.top-right { display: flex; align-items: baseline; gap: 12px; }
.top-act { color: var(--accent-hi); font-size: 16px; font-weight: 600; padding: 8px 6px; min-width: 44px; min-height: 40px; white-space: nowrap; }
.sel-bar { max-width: var(--w); margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 4px 12px; min-height: 52px; }
.sel-count { font-size: 18px; font-weight: 700; text-align: center; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .pick { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .28); display: grid; place-items: center; color: #fff; }
.row .pick .ic { width: 16px; height: 16px; stroke-width: 2.6; opacity: 0; }
.row.on .pick { background: var(--accent); border-color: var(--accent); }
.row.on .pick .ic { opacity: 1; }
.row.on { background: var(--card2); }
.sel-foot { position: fixed; z-index: 26; left: 0; right: 0; bottom: 0; padding: 12px 16px calc(12px + var(--safe-b)); background: var(--bg-top); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
.sel-foot .btn { display: block; width: 100%; max-width: var(--w); margin: 0 auto; }
.btn.danger:not(:disabled) { background: var(--danger); color: #fff; }
#v-app.selecting .fab-wrap { display: none; }

/* ---------- 저장 줄 알약(접어 둔 여러 장 저장) ---------- */
.qpill { display: flex; align-items: center; gap: 8px; max-width: var(--w); width: calc(100% - 32px); margin: 4px auto 6px; padding: 10px 14px; border-radius: 12px; background: var(--card2); color: var(--ink); font-size: 14px; font-weight: 600; text-align: left; }
.qpill::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); animation: pulse 1.2s infinite; }
.qpill.done::before { background: var(--ok); animation: none; }
.qpill.bad::before { background: var(--danger); animation: none; }

/* ---------- 여러 장 저장 창 ---------- */
.qsheet { align-items: end; padding: 0; }
.q-panel { width: min(560px, 100%); max-height: 82vh; max-height: 82dvh; display: flex; flex-direction: column; border-radius: 20px 20px 0 0; background: var(--card); padding: 18px 16px calc(16px + var(--safe-b)); box-shadow: 0 -10px 40px rgba(0, 0, 0, .45); }
.q-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.q-head b { font-size: 18px; }
.q-head span { color: var(--sub); font-size: 14px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.q-bar { height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .08); overflow: hidden; margin-bottom: 12px; }
.q-bar i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .3s; }
.q-list { list-style: none; margin: 0 -4px 14px; padding: 0 4px; overflow-y: auto; -webkit-overflow-scrolling: touch; flex: 1; min-height: 0; }
.q-item { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
.q-item + .q-item { border-top: 1px solid var(--line); }
.q-item .thumb { width: 84px; }
.q-item .q-txt { flex: 1; min-width: 0; }
.q-item .q-name { font-size: 15px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.q-item .q-st { margin-top: 2px; font-size: 13px; color: var(--sub); }
.q-item .q-st.on { color: var(--accent-hi); }
.q-item .q-st.ok { color: var(--ok); }
.q-item .q-st.bad { color: var(--danger); }
.q-item.tap { cursor: pointer; }

/* ---------- 촬영(앱 안 카메라, 찰칵 소리 없음) ---------- */
.cam { position: fixed; inset: 0; z-index: 70; background: #000; color: #fff; overflow: hidden; }
.cam video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }
.cam-shade { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; }
.cam-guide { position: relative; width: min(88vw, 520px); aspect-ratio: 9 / 5; border-radius: 12px; box-shadow: 0 0 0 200vmax rgba(0, 0, 0, .45); }
.cam-guide .k { position: absolute; width: 26px; height: 26px; border: 3px solid #fff; }
.cam-guide .tl { left: -2px; top: -2px; border-right: 0; border-bottom: 0; border-top-left-radius: 12px; }
.cam-guide .tr { right: -2px; top: -2px; border-left: 0; border-bottom: 0; border-top-right-radius: 12px; }
.cam-guide .bl { left: -2px; bottom: -2px; border-right: 0; border-top: 0; border-bottom-left-radius: 12px; }
.cam-guide .br { right: -2px; bottom: -2px; border-left: 0; border-top: 0; border-bottom-right-radius: 12px; }
.cam-hint { position: absolute; left: 0; right: 0; top: calc(50% + min(88vw, 520px) * 5 / 18 + 18px); margin: 0; text-align: center; font-size: 15px; text-shadow: 0 1px 4px rgba(0, 0, 0, .6); }
.cam-top { position: absolute; left: 0; right: 0; top: 0; padding: calc(12px + var(--safe-t)) 14px 12px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; }
.cam-x { justify-self: start; padding: 8px 12px; border-radius: 10px; background: rgba(0, 0, 0, .45); font-size: 16px; font-weight: 600; }
.cam-count { justify-self: end; grid-column: 3; padding: 6px 12px; border-radius: 10px; background: rgba(0, 0, 0, .45); font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cam-count:empty { display: none; }
.cam-bottom { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 24px calc(26px + var(--safe-b)); display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.cam-last { justify-self: start; width: 64px; aspect-ratio: 9 / 5; border-radius: 6px; overflow: hidden; background: rgba(255, 255, 255, .12); position: relative; }
.cam-last:empty { visibility: hidden; }
.cam-last img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cam-shutter { width: 76px; height: 76px; border-radius: 50%; border: 4px solid #fff; display: grid; place-items: center; }
.cam-shutter i { width: 60px; height: 60px; border-radius: 50%; background: #fff; transition: transform .1s; }
.cam-shutter:active i { transform: scale(.88); }
.cam-shutter:disabled { opacity: .4; }
.cam-done { justify-self: end; padding: 10px 16px; border-radius: 12px; background: rgba(255, 255, 255, .16); font-size: 16px; font-weight: 700; }
.cam-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.cam-flash.go { animation: camflash .28s ease-out; }
@keyframes camflash { 0% { opacity: .75; } 100% { opacity: 0; } }
.cam-msg { position: absolute; left: 16px; right: 16px; top: 50%; transform: translateY(-50%); max-width: 380px; margin: 0 auto; padding: 20px 18px 18px; border-radius: 18px; background: var(--card); color: var(--ink); text-align: center; }
.cam-msg p { margin: 0 0 16px; font-size: 15px; line-height: 1.55; }

/* ---------- 명함 보기에 더한 것 ---------- */
.info dd { display: flex; flex-direction: column; gap: 8px; }
.info .val { display: flex; align-items: center; gap: 8px; min-width: 0; }
.info .val > .tx { flex: 1; min-width: 0; }
/* 전화번호는 두 줄로 꺾이지 않게 */
.info .val.num > .tx { white-space: nowrap; }
.info .acts { flex: none; display: flex; gap: 6px; }
.info .act { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: rgba(47, 111, 255, .16); color: var(--accent-hi); text-decoration: none; }
.info .act .ic { width: 19px; height: 19px; }
.dups { margin: 0 0 14px; padding: 12px 14px; border-radius: 14px; background: rgba(240, 160, 40, .12); color: #ffd28a; font-size: 14px; }
.dups p { margin: 0 0 6px; font-weight: 650; }
.dups button { display: block; width: 100%; text-align: left; padding: 6px 0; color: var(--ink); font-size: 14.5px; }
.dups button small { color: var(--sub); margin-left: 6px; }
.memo { margin-top: 12px; padding: 14px 16px; border-radius: var(--radius); background: var(--card); }
.memo h3 { margin: 0 0 6px; font-size: 13.5px; font-weight: 600; color: var(--sub2); }
.memo p { margin: 0; font-size: 15.5px; white-space: pre-wrap; word-break: keep-all; overflow-wrap: anywhere; -webkit-user-select: text; user-select: text; }
.btn.wide { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; margin-top: 14px; }
.btn.wide .ic { width: 20px; height: 20px; }
#confirm { z-index: 75; }
/* 아주 좁은 휴대폰: 번호 옆 단추가 들어갈 자리를 만든다 */
@media (max-width: 360px) {
  .info > div { grid-template-columns: 54px 1fr; padding: 13px 12px; }
  .info .act { width: 34px; height: 34px; }
}
@media (max-width: 340px) {
  .info dd { font-size: 15px; }
}

/* ---------- 세로 명함: 촬영 화면의 틀을 세로로 ---------- */
.cam-seg { display: flex; padding: 3px; border-radius: 12px; background: rgba(0, 0, 0, .5); }
.cam-seg button { padding: 7px 14px; border-radius: 9px; font-size: 15px; font-weight: 600; color: rgba(255, 255, 255, .78); }
.cam-seg button[aria-pressed="true"] { background: #fff; color: #0b111c; }
.cam.portrait .cam-guide { width: min(76vw, calc(56vh * 5 / 9), 330px); aspect-ratio: 5 / 9; }
.cam.portrait .cam-hint { top: calc(50% + min(76vw, calc(56vh * 5 / 9), 330px) * 9 / 10 + 18px); }
.cam.portrait .cam-last { width: 38px; aspect-ratio: 5 / 9; }
