/* ============================================================================
   장바구니 담김 팝업 — 리디자인, 모든 화면(옛 화면 포함)

   마크업은 rd-cartadded.js 가 처음 담길 때 한 번 만든다. 둘 다 common/header.jsp 가 싣는다.
   · 화면 가운데 작은 창 + 어둡게 깐 바탕. 바탕을 누르거나 [계속 보기] · Esc 면 닫힌다
   · 옛 화면의 가장 높은 층(common.css 999)보다 위에 뜬다
   ============================================================================ */

.ca-dim {
    position: fixed;
    left: 0; right: 0; top: 0; bottom: 0;
    z-index: 1000;
    background: rgba(16, 22, 35, .45);
    opacity: 0;
    transition: opacity var(--t-base, .2s);
}
.ca-dim.is-on { opacity: 1; }

.ca-box {
    position: fixed;
    left: 50%;
    top: 50%;
    z-index: 1001;
    width: calc(100% - 48px);
    max-width: 320px;
    padding: 28px 20px 20px;
    border-radius: var(--r-modal, 16px);
    background: #fff;
    box-shadow: 0 12px 40px rgba(16, 22, 35, .18);
    text-align: center;
    opacity: 0;
    transform: translate(-50%, -46%);
    transition: opacity var(--t-base, .2s), transform var(--t-base, .2s);
}
.ca-box.is-on { opacity: 1; transform: translate(-50%, -50%); }

.ca-box .ca-ic {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin: 0 auto 14px;
    border-radius: 50%;
    background: var(--c-brand-50, #eef3ff);
    color: var(--c-brand, #2f5bea);
}
.ca-box .ca-ic svg { display: block; width: 24px; height: 24px; }

.ca-box .ca-tt {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: -.02em;
    color: var(--c-text-title, #111);
}
.ca-box .ca-ds {
    margin: 6px 0 0;
    font-size: 14px;
    line-height: 1.5;
    letter-spacing: -.01em;
    color: var(--c-text-sub, #666);
}

.ca-box .ca-bt {
    display: flex;
    gap: 8px;
    margin-top: 22px;
}
.ca-box .ca-bt button {
    flex: 1 1 0;
    min-width: 0;
    height: 48px;
    margin: 0;
    padding: 0 8px;
    border: 0;
    border-radius: var(--r-md, 10px);
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -.01em;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}
.ca-box .ca-keep { background: var(--c-fill, #f1f3f6); color: var(--c-text-body, #333); }
.ca-box .ca-go   { background: var(--c-brand, #2f5bea); color: #fff; }
.ca-box .ca-bt button:active { transform: scale(.98); }
.ca-box .ca-bt button:focus-visible { outline: 2px solid var(--c-brand, #2f5bea); outline-offset: 2px; }

@media (prefers-reduced-motion: reduce) {
    .ca-dim, .ca-box { transition: none; }
}
