/* LeadSign 고객 화면 */

/* 콘솔(console.css)과 같은 남색·로열 블루. 서명자가 받는 화면도 같은 회사의 것으로 보여야 한다. */
:root {
    --bs-ink: #15171c;
    --bs-ink-mid: #4a4f5a;
    --bs-ink-light: #858a95;
    --bs-line: #e3e5e9;
    --bs-line-soft: #eff0f3;
    --bs-bg: #f4f5f7;
    --bs-radius: 10px;
    --bs-primary: #162836;
    --bs-accent: #2554eb;
    --bs-accent-deep: #1b41c9;
    --bs-accent-text: #1b41c9;
    --bs-accent-soft: #edf1fe;
    --bs-focus: 0 0 0 3px rgba(37, 84, 235, .22);
    --bs-ok: #12805c;
    --bs-ok-soft: #e8f6ef;
    /* 예전 이름 — 아래 규칙들이 그대로 쓴다. */
    --bs-blue: var(--bs-primary);
    --bs-blue-dark: #0d1a24;
    --bs-display: "Paperlogy", "Pretendard Variable", "Pretendard", "Malgun Gothic", sans-serif;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bs-bg);
    color: var(--bs-ink);
    font-family: "Pretendard Variable", "Pretendard", "Malgun Gothic", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 15px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
button { font-family: inherit; }

/* ── 머리말 ────────────────────────────────────────────────── */

.bs-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 24px;
    background: #fff;
    border-bottom: 1px solid var(--bs-line);
    position: sticky;
    top: 0;
    z-index: 30;
}

.bs-header__logo { font-family: var(--bs-display); font-size: 19px; font-weight: 700; letter-spacing: -.05em; text-decoration: none; }

.bs-header__logo em { font-style: normal; color: var(--bs-accent); }

.bs-header__doc { flex: 1; min-width: 0; text-align: center; font-weight: 600;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.bs-wrap { max-width: 1080px; margin: 0 auto; padding: 24px 20px 80px; }

.bs-center { max-width: 460px; margin: 0 auto; padding: 60px 20px; }

/* ── 카드 · 버튼 ───────────────────────────────────────────── */

.bs-card {
    background: #fff;
    border: 1px solid var(--bs-line);
    border-radius: var(--bs-radius);
    padding: 24px;
}

.bs-card h1 { margin: 0 0 8px; font-family: var(--bs-display); font-size: 24px; font-weight: 700; letter-spacing: -.03em; }

.bs-card h2 { margin: 0 0 14px; font-family: var(--bs-display); font-size: 17px; font-weight: 700; letter-spacing: -.02em; }

.bs-muted { color: var(--bs-ink-light); }

.bs-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 46px;
    padding: 0 20px;
    border: 1px solid var(--bs-line);
    border-radius: 8px;
    background: #fff;
    color: var(--bs-ink);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
}

.bs-btn:hover { background: #f7f8fa; }

.bs-btn--primary { background: var(--bs-blue); border-color: var(--bs-blue); color: #fff; }
.bs-btn--primary:hover { background: var(--bs-blue-dark); }
.bs-btn--block { width: 100%; }
.bs-btn--sm { height: 40px; padding: 0 14px; font-size: 14px; }
.bs-btn--ghost { background: transparent; border-color: transparent; color: var(--bs-ink-light); }

.bs-input {
    width: 100%;
    padding: 13px 14px;
    border: 1px solid var(--bs-line);
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
}

.bs-input:focus { outline: none; border-color: var(--bs-accent-deep); box-shadow: var(--bs-focus); }

.bs-input::placeholder { color: #a6abb4; }

:focus-visible { outline: 2px solid var(--bs-accent); outline-offset: 2px; }

/* 한글은 어절 단위로 줄을 바꾼다. 기본값(글자 단위)이면 「필 / 요하지」 처럼 낱말 한가운데서
   끊긴다. 띄어쓰기 없이 긴 값(주소·지문)만 넘칠 때 아무 데서나 끊어 칸 밖으로 새지 않게 한다.
   제목은 줄 길이를 고르게, 문단은 마지막 줄에 한 낱말만 남지 않게 맞춘다. */
body { word-break: keep-all; overflow-wrap: anywhere; }

h1, h2, h3 { text-wrap: balance; }

p, li { text-wrap: pretty; }

/* 사인 색 고르기. 이 규칙이 없어서 고객 화면에서는 동그라미가 납작한 막대로 보였다. */
.bs-inks { display: flex; gap: 8px; margin-bottom: 8px; }

.bs-ink {
    width: 26px;
    height: 26px;
    padding: 0;
    border: 2px solid #fff;
    border-radius: 50%;
    background: var(--ink);
    box-shadow: 0 0 0 1px var(--bs-line);
    cursor: pointer;
}

.bs-ink.is-on { box-shadow: 0 0 0 2px var(--ink); }

.bs-code {
    letter-spacing: 10px;
    text-align: center;
    font-size: 22px;
    font-weight: 700;
}

.bs-alert {
    margin: 0 0 14px;
    padding: 11px 14px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
}

.bs-alert--error { background: #fdecea; color: #b3261e; }
.bs-alert--ok { background: var(--bs-ok-soft); color: var(--bs-ok); }

.bs-sub { margin: 20px 0 8px; font-size: 13px; font-weight: 700; color: var(--bs-ink-mid); }

/* ── 서명 화면 ─────────────────────────────────────────────── */

.bs-sign { display: grid; grid-template-columns: 300px minmax(0, 1fr) 176px; gap: 18px; align-items: start; }

.bs-sign__panel { position: sticky; top: 78px; }

.bs-stamps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }

.bs-stamp {
    border: 1px solid var(--bs-line);
    border-radius: 8px;
    padding: 8px;
    background: #fff;
    cursor: pointer;
    width: 100%;
}

.bs-stamp.is-chosen { border-color: var(--bs-accent-deep); box-shadow: var(--bs-focus); }

.bs-stamp img { width: 100%; display: block; }

.bs-pad {
    width: 100%;
    height: 160px;
    border: 1px dashed var(--bs-line);
    border-radius: 8px;
    background: #fff;
    touch-action: none;
    display: block;
}

/* ── 문서 보기 ─────────────────────────────────────────────── */

.bs-viewer { display: flex; flex-direction: column; gap: 18px; }

.bs-page {
    position: relative;
    background: #fff;
    border: 1px solid var(--bs-line);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .06);
}

.bs-page__inner { position: relative; width: 100%; height: 0; }

.bs-page__img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

.bs-page__no {
    position: absolute;
    top: 8px; left: 10px;
    padding: 2px 8px;
    border-radius: 4px;
    background: rgba(0, 0, 0, .55);
    color: #fff;
    font-size: 11px;
    z-index: 4;
}

.bs-mark {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid currentColor;
    border-radius: 4px;
    background: rgba(255, 255, 255, .55);
    z-index: 5;
}

.bs-mark__icon { width: 26%; height: 26%; opacity: .9; }

.bs-mark__name {
    position: absolute;
    top: -20px; left: -2px;
    padding: 1px 6px;
    border-radius: 3px;
    /* currentColor 를 쓰면 바로 아래 color:#fff 가 그대로 배경이 되어 이름표가 사라진다.
       칸 색은 스크립트가 --mark-color 로 따로 내려 준다. */
    background: var(--mark-color, #1f6feb);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}

.bs-mark__del { display: none; }

.bs-mark__img { width: 100%; height: 100%; object-fit: contain; }

.bs-mark.is-filled { border-style: solid; background: transparent; }

/* 데려간 자리. 「여기」 를 눈으로 짚어 준다 — 화면이 움직이고 끝나면 어디를 봤는지 잊는다.
   테두리 대신 바깥으로 번지는 그림자를 쓴다. 칸 크기가 흔들리면 서명 자리가 밀려 보인다. */
.bs-mark.is-calling {
    animation: bs-calling 1.1s ease-out 2;
    z-index: 5;
}

@keyframes bs-calling {
    0%   { box-shadow: 0 0 0 0 var(--mark-color, #1f6feb); }
    70%  { box-shadow: 0 0 0 12px transparent; }
    100% { box-shadow: 0 0 0 0 transparent; }
}

/* 움직임을 꺼 둔 사람에게는 깜빡이지 않고 한 번 또렷하게만 보여 준다. */
@media (prefers-reduced-motion: reduce) {
    .bs-mark.is-calling {
        animation: none;
        box-shadow: 0 0 0 3px var(--mark-color, #1f6feb);
    }
}


/* 놓은 칸의 크기 조절 손잡이 */
.bs-mark__resize {
    position: absolute;
    right: -6px; bottom: -6px;
    width: 12px; height: 12px;
    border-radius: 3px;
    border: 2px solid currentColor;
    background: #fff;
    cursor: nwse-resize;
    display: none;
}

.bs-mark:hover .bs-mark__resize { display: block; }

/* 서명 화면 — 내가 채울 칸만 도드라지게. 남의 칸은 있다는 것만 알면 된다.
   빛깔은 칸마다 다르므로(--mark-color) 파랑을 박아 두지 않는다. 박아 두면 주황 칸에
   파란 테가 둘리고, 그때부터 색은 누구 자리인지 아무것도 말해 주지 않는다. */

.bs-mark.is-mine { border-width: 2px; }

/* ① 아직 비어 있는 내 칸. 화면에서 가장 먼저 보여야 하는 것이다.
      빈 입력 칸처럼 옅게 칠하고 바깥으로 테를 한 겹 더 둘러, 종이 위에 떠 보이게 한다. */
.bs-mark.is-mine[data-mine="empty"] {
    border-style: solid;
    background: color-mix(in srgb, var(--mark-color) 16%, #fff);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--mark-color) 32%, transparent),
                0 2px 8px rgba(27, 27, 27, .14);
    animation: bs-pulse 1.8s ease-in-out infinite;
}

/* 이름표도 같이 또렷하게. 무엇을 적는 자리인지가 칸보다 먼저 읽힌다. */
.bs-mark.is-mine[data-mine="empty"] .bs-mark__name { box-shadow: 0 1px 3px rgba(27, 27, 27, .25); }

.bs-mark.is-mine[data-mine="empty"] .bs-mark__icon { opacity: 1; }

/* ② 이미 채운 내 칸. 다 되었다는 것만 조용히 알린다. */
.bs-mark.is-mine[data-mine="filled"] {
    border-style: solid;
    background: transparent;
    box-shadow: none;
    animation: none;
}

/* ③ 남의 칸. 있다는 것만 알면 된다 — 색기를 빼서 내 칸과 한눈에 갈라 놓는다. */
.bs-mark.is-other {
    opacity: .3;
    border-width: 1px;
    border-style: dashed;
    filter: grayscale(.7);
}

@keyframes bs-pulse {
    0%, 100% { box-shadow: 0 0 0 3px color-mix(in srgb, var(--mark-color) 32%, transparent),
                           0 2px 8px rgba(27, 27, 27, .14); }
    50%      { box-shadow: 0 0 0 9px color-mix(in srgb, var(--mark-color) 14%, transparent),
                           0 2px 8px rgba(27, 27, 27, .14); }
}

@media (prefers-reduced-motion: reduce) {
    .bs-mark.is-mine[data-mine="empty"] { animation: none; }
}


/* ── 마침 ──────────────────────────────────────────────────── */

.bs-done { text-align: center; }

.bs-done__icon {
    width: 64px; height: 64px;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: var(--bs-ok-soft);
    color: var(--bs-ok);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
}

@media (max-width: 1180px) {
    .bs-sign { grid-template-columns: 300px minmax(0, 1fr); }
    .bs-thumbs { display: none; }
}

@media (max-width: 900px) {
    .bs-sign { grid-template-columns: minmax(0, 1fr); }
    .bs-sign__panel { position: static; }
}

/* ── 남은 서명 자리 안내 ───────────────────────────────────── */

.bs-progress-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin: 4px 0 6px;
    padding: 10px 12px;
    border-radius: 8px;
    background: var(--bs-accent-soft);
    color: var(--bs-accent-text);
    font-size: 13px;
    font-weight: 600;
}

.bs-progress-line.is-done { background: var(--bs-ok-soft); color: var(--bs-ok); }

.bs-progress-line b { font-size: 15px; }

.bs-linkbtn {
    background: none;
    border: 0;
    padding: 0;
    color: inherit;
    font-size: 12px;
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
}

.bs-btn[disabled] { opacity: .45; cursor: not-allowed; }

/* PDF 로 바꾸지 못한 문서 자리 */
.bs-page--unreadable {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 48px 24px;
    text-align: center;
    color: #8a8a8a;
    font-size: 14px;
}

.bs-page--unreadable b { color: #1b1b1b; font-size: 15px; }

/* 여러 쪽을 훑을 때 지금 쪽을 알려 주는 배지 */
.bs-pageno {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 40;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(27, 27, 27, .82);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    pointer-events: none;
}

/* ── 옆에 세우는 쪽 목록 ───────────────────────────────────── */

.bs-thumbs {
    position: sticky;
    top: 20px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    background: #fff;
    border: 1px solid var(--bs-line);
    border-radius: var(--bs-radius);
    padding: 0 0 10px;
}

.bs-thumbs__head {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 12px 14px;
    background: #fff;
    border-bottom: 1px solid var(--bs-line-soft);
    font-size: 13px;
    font-weight: 700;
    color: var(--bs-ink-light);
}

.bs-thumbs__doc { padding: 10px 0 4px; }

.bs-thumbs__name {
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    padding: 4px 14px;
    border: 0;
    background: none;
    cursor: pointer;
    text-align: left;
    font-size: 12px;
    font-weight: 600;
    color: var(--bs-ink-mid);
}

.bs-thumbs__name span:first-child {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bs-thumbs__chev { flex: none; font-size: 10px; color: var(--bs-ink-light); }

.bs-thumbs__count { padding: 0 14px 8px; font-size: 11px; color: var(--bs-ink-light); }

.bs-thumbs__list { display: flex; flex-direction: column; align-items: center; gap: 10px; }

.bs-thumbs__list[hidden] { display: none; }

.bs-thumb {
    position: relative;
    width: 120px;
    padding: 0;
    border: 1px solid var(--bs-line);
    border-radius: 4px;
    background: #fff;
    cursor: pointer;
    overflow: hidden;
    line-height: 0;
}

.bs-thumb img { width: 100%; height: auto; display: block; }

.bs-thumb.is-current {
    border-color: var(--bs-blue);
    box-shadow: var(--bs-focus);
}

.bs-thumb__no {
    position: absolute;
    left: 4px;
    bottom: 4px;
    padding: 1px 6px;
    border-radius: 3px;
    background: rgba(27, 27, 27, .72);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.4;
}

.bs-thumb--empty {
    width: 120px;
    padding: 26px 8px;
    border: 1px dashed var(--bs-line);
    border-radius: 4px;
    text-align: center;
    font-size: 11px;
    color: var(--bs-ink-light);
}

/* ── 도구를 고르면 마우스를 따라다니는 네모 ────────────────── */

.bs-ghost {
    position: fixed;
    z-index: 60;
    display: none;
    align-items: center;
    justify-content: center;
    border: 2px dashed currentColor;
    border-radius: 4px;
    background: rgba(255, 255, 255, .55);
    pointer-events: none;
}

.bs-ghost.is-on { display: flex; }

.bs-ghost svg { width: 26%; height: 26%; opacity: .9; }

.bs-ghost__name {
    position: absolute;
    top: -20px;
    left: -2px;
    padding: 1px 6px;
    border-radius: 3px;
    background: var(--mark-color, #1f6feb);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}

/* ── 완성본 보기 ────────────────────────────────────────────
   서명이 끝난 문서를 PDF 파일이 아니라 화면에서 본다. 방(room)과 달리 옆 패널도
   입력란도 없고 쪽 그림만 세로로 내려간다 — 볼 것과 내려받을 것 둘뿐이다. */

.bs-doc { max-width: 900px; margin: 0 auto; padding: 24px 20px 60px; }

.bs-doc__bar {
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 20px;
    padding: 14px 0;
    background: var(--bs-bg);
}

.bs-doc__title { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.bs-doc__title b { font-size: 18px; font-weight: 800; letter-spacing: -0.3px; }
.bs-doc__title span { font-size: 14px; }

.bs-doc__actions { display: flex; gap: 8px; }

.bs-doc__pages { display: flex; flex-direction: column; gap: 16px; }

.bs-doc__foot { margin: 24px 0 0; font-size: 13px; text-align: center; }

@media (max-width: 640px) {
    .bs-doc__bar { flex-direction: column; align-items: stretch; }
    .bs-doc__actions .bs-btn { width: 100%; }
}

/* ── 서명자가 채우는 칸 ─────────────────────────────────────
   사인·도장 말고도 글자·날짜·체크박스를 문서 위에서 바로 채운다.
   자동입력 칸은 이미 채워져 있으므로, 누를 수 있는 칸과 눈에 띄게 갈라 놓는다. */

/* 저절로 채워진 칸. 눌러도 아무 일이 없으니 눌러 보고 싶게 생기면 안 된다. */
.bs-mark.is-auto {
    --mark-color: #8a8a8a;
    color: #8a8a8a;
    border-style: dotted;
}

.bs-mark.is-auto.is-mine { border-width: 2px; box-shadow: none; animation: none; }

/* 내가 눌러 채울 수 있는 칸. */
.bs-mark.is-editable { cursor: pointer; }
.bs-mark.is-editable:hover { filter: brightness(.96); }

.bs-mark.is-saving { opacity: .55; pointer-events: none; }

/* 칸 위에 그대로 뜨는 입력 칸. 어디에 적는 것인지 눈을 떼지 않게 한다. */
.bs-mark__input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    padding: 0 6px;
    border: 2px solid var(--mark-color, #1f6feb);
    border-radius: 4px;
    background: #fff;
    color: var(--bs-ink, #1c1c1c);
    font-family: inherit;
    font-size: 13px;
}

.bs-mark__input:focus { outline: none; }

/* 아직 비어 있는 칸에 흐리게 보여 주는 안내. 무엇을 적는 자리인지 이름표보다 먼저 읽힌다. */
.bs-mark__guide {
    max-width: 92%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 12px;
    color: #6b7280;
    opacity: .9;
}

/* ── 서명 방 ────────────────────────────────────────────────
   머리말과 아래 단추 줄은 붙박이, 가운데 세 칸만 각자 흐른다. 쪽을 내리다
   「서명 시작하기」 를 놓치면 서명자는 무엇을 해야 할지 알 길이 없다.

   화면 전체를 세로로 셋(머리말·본문·단추 줄)으로 나누는 일은 body 가 맡는다.
   머리말 높이를 숫자로 박아 두면 이름이 길어질 때마다 어긋난다. */

body.is-room {
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
}

body.is-room .bs-header { flex: none; position: static; }

.bs-room {
    flex: 1;
    min-height: 0;
    display: grid;
    grid-template-columns: 168px minmax(0, 1fr) 320px;
}

.bs-room > * { min-width: 0; }

/* 세 칸은 저마다 흐른다 — 오른쪽 패널을 보려고 문서를 내릴 일이 없어야 한다. */
.bs-room__side {
    overflow-y: auto;
    background: #fff;
    border-right: 1px solid var(--bs-line);
}

.bs-room__main {
    overflow-y: auto;
    padding: 20px;
    scroll-padding: 80px 0;
}

.bs-room__panel {
    overflow-y: auto;
    padding: 16px;
    background: #fff;
    border-left: 1px solid var(--bs-line);
}

.bs-room .bs-viewer { max-width: 860px; margin: 0 auto; }

.bs-room .bs-card { border: 0; border-radius: 0; padding: 0; }

/* 쪽 목록은 이미 제 칸이 흐르므로 sticky 도 테두리도 필요 없다. */
.bs-room .bs-thumbs {
    position: static;
    max-height: none;
    overflow: visible;
    border: 0;
    border-radius: 0;
    padding: 0 0 16px;
}

.bs-room .bs-thumb, .bs-room .bs-thumb--empty { width: 108px; }

/* ── 아래 단추 줄 ──────────────────────────────────────────── */

.bs-actionbar {
    flex: none;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: #fff;
    border-top: 1px solid var(--bs-line);
    box-shadow: 0 -2px 10px rgba(0, 0, 0, .05);
    z-index: 20;
}

.bs-actionbar__gap { flex: 1; }

.bs-actionbar__count { font-size: 13px; color: var(--bs-ink-mid); }
.bs-actionbar__count b { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; }

.bs-actionbar .bs-btn { min-width: 128px; }

/* 쪽 배지가 단추 줄에 깔리지 않게 위로 올린다. */
body.is-room .bs-pageno { bottom: 84px; }

@media (max-width: 1180px) {
    .bs-room { grid-template-columns: minmax(0, 1fr) 320px; }
    .bs-room__side { display: none; }
}

/* 좁은 화면에서는 붙박이를 풀고 위에서 아래로 늘어놓는다. 세로로 셋을 쌓으면
   어느 칸도 제 몫을 못 한다. 단추 줄만 아래에 붙여 둔다. */
@media (max-width: 900px) {
    body.is-room { display: block; height: auto; overflow: visible; }

    .bs-room { display: block; }

    .bs-room__main { overflow: visible; padding: 16px; }

    .bs-room__panel {
        overflow: visible;
        border-left: 0;
        border-top: 1px solid var(--bs-line);
    }

    .bs-actionbar { position: sticky; bottom: 0; }

    .bs-actionbar__count { display: none; }
}

/* ── 안내 화면 (오류·차례 아님·완료·본인 확인) ─────────────────
   화면마다 따로 놀던 안내를 한 틀로 모은다. 그림 한 장, 제목 한 줄, 설명, 단추 —
   언제나 남은 자리의 한가운데에 선다. */

.bs-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - var(--bs-state-offset, 61px));
    padding: 40px 20px 72px;
    text-align: center;
}

.bs-state__art {
    display: block;
    width: 200px;
    height: 200px;
    margin: 0 0 8px;
    object-fit: contain;
}

.bs-state__title {
    margin: 0 0 10px;
    font-family: var(--bs-display);
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -.035em;
    line-height: 1.35;
    color: var(--bs-ink);
}

.bs-state__msg {
    max-width: 440px;
    margin: 0;
    font-size: 15px;
    line-height: 1.7;
    color: var(--bs-ink-mid);
    word-break: keep-all;
}

.bs-state__msg b { color: var(--bs-ink); }

.bs-state__code { margin: 12px 0 0; font-size: 13px; color: var(--bs-ink-light); }

.bs-state__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 28px; }

/* 입력을 받는 안내(본인 확인)는 카드 하나를 그림 아래에 세운다. */
.bs-state--form { justify-content: flex-start; padding-top: 6vh; }

.bs-state__card {
    width: 100%;
    max-width: 420px;
    padding: 28px;
    text-align: left;
}

@media (max-width: 600px) {
    .bs-state__art { width: 160px; height: 160px; }
    .bs-state__title { font-size: 22px; }
}

/* 로고 마크(LS 서명 모노그램) + 글자 로고. 마크는 글자 크기를 따라 커지고 작아진다. */
.bs-rail__brand, .bs-header__logo, .ld-logo {
    display: inline-flex;
    align-items: center;
    gap: .4em;
}

.bs-logomark { width: 1.2em; height: 1.2em; flex: none; border-radius: 24%; }

/* ── 링크 서명 첫 화면 ─────────────────────────────────────────────── */
.bs-linkform { display: grid; gap: 12px; }
.bs-linkform label { display: grid; gap: 6px; text-align: left; }
.bs-linkform label > span { font-size: 13px; font-weight: 600; color: var(--bs-ink-mid, #4a4f5a); }
.bs-linkform label small { font-weight: 400; }
.bs-linkform .bs-btn { margin-top: 6px; }
