/* ==========================================================================
   CardCashGo — 원장(ledger) 스킨
   스코프: #cc-root
   ※ 이미지 크기(PC 930x620 / 모바일 400x400 상한, 플레이스홀더 수치)는 원본 유지
   ※ CTA 이미지 width: 500px 유지
   ========================================================================== */

html, body {
    margin: 0;
    padding: 0;
    background: #efe6d6;
}

#cc-root {
    --ink: #1c1712;
    --ink-soft: #3a3229;
    --paper: #f6efe3;
    --paper-2: #ebe1d0;
    --rule: #cbbba3;
    --copper: #b45a2a;
    --copper-2: #8c3f1c;
    --sage: #3d5c4a;
    --mute: #6d6256;
    --head: #140f0c;
    --max: 1040px;
    --prose: 68ch;
    --font: "Pretendard Variable", Pretendard, "Noto Sans KR", "Malgun Gothic", sans-serif;
    --serif: "Noto Serif KR", "Source Han Serif K", "Batang", serif;

    all: revert;
    box-sizing: border-box;
    font-family: var(--font);
    background: var(--paper);
    color: var(--ink-soft);
    line-height: 1.86;
    letter-spacing: -0.015em;
    word-break: keep-all;
    overflow-wrap: anywhere;
    text-align: left;
    overflow-x: clip;
}

#cc-root *,
#cc-root *::before,
#cc-root *::after { box-sizing: border-box; }

#cc-root img { max-width: 100%; height: auto; display: block; }
#cc-root a { color: var(--copper-2); text-decoration: none; }
#cc-root a:hover { text-decoration: underline; }
#cc-root strong { color: var(--copper-2); font-weight: 700; }

#cc-root :focus-visible {
    outline: 2px solid var(--copper);
    outline-offset: 3px;
}

#cc-root .cc-inner {
    width: 100%;
    max-width: var(--max);
    margin-inline: auto;
    padding-inline: 28px;
}

#cc-root [id] { scroll-margin-top: 28px; }

#cc-root .cc-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}


/* ---------- 상단 바 (스티키 메뉴 없음) ---------- */
#cc-root .cc-top {
    border-bottom: 1px solid var(--rule);
    background: #f3eadc;
}

#cc-root .cc-top-row {
    max-width: var(--max);
    margin-inline: auto;
    padding: 18px 28px 16px;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
}

#cc-root .cc-brand {
    font-family: var(--serif);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--head);
    letter-spacing: -0.04em;
}
#cc-root .cc-brand:hover { text-decoration: none; }
#cc-root .cc-brand small {
    display: block;
    margin-top: 3px;
    font-family: var(--font);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--copper);
}

#cc-root .cc-top-skip {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--mute);
    border-bottom: 1px solid var(--rule);
}
#cc-root .cc-top-skip:hover { color: var(--copper-2); text-decoration: none; }


/* ---------- 히어로 ---------- */
#cc-root .cc-lead {
    padding: 48px 0 40px;
}

#cc-root .cc-kicker {
    margin: 0 0 18px;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--sage);
}

#cc-root h1 {
    margin: 22px 0 18px;
    max-width: 16ch;
    font-family: var(--serif);
    font-size: clamp(2.1rem, 5vw, 3.05rem);
    font-weight: 700;
    line-height: 1.28;
    letter-spacing: -0.05em;
    color: var(--head);
}

#cc-root .cc-lede {
    max-width: 58ch;
    margin: 0 0 28px;
    font-size: clamp(1.02rem, 1.5vw, 1.12rem);
    line-height: 1.95;
    color: var(--mute);
}
#cc-root .cc-lede strong { color: var(--ink); }

#cc-root .cc-cta {
    display: inline-block;
    margin: 0 0 36px;
    border-radius: 12px;
    overflow: hidden;
    line-height: 0;
    box-shadow: 0 10px 28px rgba(140, 63, 28, 0.18);
}
#cc-root .cc-cta:hover { text-decoration: none; transform: none; }
#cc-root .cc-cta img { width: 500px; max-width: 100%; height: auto; }


/* ---------- 이미지 (크기 규칙 원본 유지) ---------- */
#cc-root .bm-figure {
    margin: 0 0 44px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--rule);
    box-shadow: 0 12px 32px rgba(28, 23, 18, 0.08);
}
#cc-root .bm-figure img { width: 100%; }
#cc-root .bm-figure-hero { margin-bottom: 28px; }
#cc-root .bm-figure--md { max-width: 640px; margin-inline: auto; }
#cc-root .bm-figure--sq { max-width: 560px; margin-inline: auto; }
#cc-root .bm-figure--wide { max-width: 930px; margin-inline: auto; }
#cc-root .cc-copy + .bm-figure { margin-top: 40px; }


/* ---------- 목차 (단열 레일) ---------- */
#cc-root .cc-rail {
    margin: 8px 0 0;
    padding: 0;
    border-top: 2px solid var(--ink);
}
#cc-root .cc-rail-h {
    margin: 14px 0 10px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--copper);
}
#cc-root .cc-rail ol {
    margin: 0;
    padding: 0;
    list-style: none;
}
#cc-root .cc-rail a {
    display: grid;
    grid-template-columns: 2.4rem 1fr;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid var(--rule);
    color: var(--ink);
    font-size: 0.95rem;
    line-height: 1.5;
}
#cc-root .cc-rail a:hover {
    color: var(--copper-2);
    text-decoration: none;
}
#cc-root .cc-rail b {
    font-variant-numeric: tabular-nums;
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--sage);
}


/* ---------- 본문 섹션 ---------- */
#cc-root .cc-slice { padding: 64px 0; }
#cc-root .cc-slice--band {
    background: var(--paper-2);
    border-block: 1px solid var(--rule);
}

#cc-root .cc-headpair {
    display: grid;
    grid-template-columns: minmax(0, 220px) minmax(0, 1fr);
    gap: 18px 40px;
    margin-bottom: 28px;
    align-items: start;
}
#cc-root .cc-num {
    margin: 0;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--sage);
}
#cc-root h2 {
    margin: 0;
    font-family: var(--serif);
    font-size: clamp(1.38rem, 2.6vw, 1.82rem);
    font-weight: 700;
    line-height: 1.42;
    letter-spacing: -0.035em;
    color: var(--head);
}

#cc-root h3 {
    margin: 36px 0 12px;
    font-size: clamp(1.05rem, 1.7vw, 1.18rem);
    font-weight: 800;
    line-height: 1.5;
    color: var(--copper-2);
}

#cc-root .cc-copy { max-width: var(--prose); }
#cc-root .cc-copy p {
    margin: 0 0 22px;
    font-size: 1.02rem;
    line-height: 1.95;
    color: #3f372f;
}
#cc-root .cc-copy p:last-child { margin-bottom: 0; }
#cc-root .cc-faq-cta { margin-top: 36px; }

#cc-root .cc-note {
    margin: 0 0 28px;
    padding: 16px 18px;
    background: #f8f1e6;
    border-left: 3px solid var(--copper);
}
#cc-root .cc-note p {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.8;
    color: var(--ink);
}


/* ---------- 비교표 / 카드 / 스텝 ---------- */
#cc-root .cc-tablewrap {
    max-width: 940px;
    margin: 0 0 36px;
    overflow-x: auto;
    border: 1px solid var(--rule);
    background: #faf6ee;
}
#cc-root .cc-table {
    width: 100%;
    min-width: 560px;
    border-collapse: collapse;
    font-size: 0.93rem;
}
#cc-root .cc-table th {
    padding: 12px 14px;
    text-align: left;
    font-weight: 700;
    color: var(--head);
    background: #e5d8c2;
    border-bottom: 1px solid var(--rule);
}
#cc-root .cc-table td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--rule);
    vertical-align: top;
    color: #4a4036;
}

#cc-root .cc-steps {
    display: grid;
    gap: 0;
    margin: 0 0 32px;
    padding: 0;
    list-style: none;
    border-top: 1px solid var(--rule);
}
#cc-root .cc-steps li {
    display: grid;
    grid-template-columns: 4.5rem 1fr;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid var(--rule);
}
#cc-root .cc-steps b {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: var(--sage);
}
#cc-root .cc-steps strong {
    display: block;
    margin-bottom: 4px;
    color: var(--head);
}

#cc-root .cc-chips {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 10px;
    margin: 0 0 32px;
    padding: 0;
    list-style: none;
}
#cc-root .cc-chips li {
    padding: 16px 16px 14px;
    background: #faf6ee;
    border: 1px solid var(--rule);
}
#cc-root .cc-chips strong {
    display: block;
    margin-bottom: 6px;
    color: var(--head);
}
#cc-root .cc-chips span {
    display: block;
    font-size: 0.88rem;
    line-height: 1.7;
    color: var(--mute);
}

#cc-root .cc-weeks {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 0 0 28px;
}
#cc-root .cc-weeks article {
    padding: 16px 16px 14px;
    background: #faf6ee;
    border-top: 3px solid var(--sage);
}
#cc-root .cc-weeks h3 {
    margin: 0 0 8px;
    font-size: 0.92rem;
    color: var(--head);
}
#cc-root .cc-weeks p {
    margin: 0;
    font-size: 0.88rem;
    line-height: 1.7;
    color: var(--mute);
}

#cc-root .cc-dl {
    max-width: 940px;
    margin: 0 0 28px;
    border-top: 1px solid var(--rule);
}
#cc-root .cc-dl div {
    display: grid;
    grid-template-columns: minmax(120px, 200px) 1fr;
    gap: 8px 20px;
    padding: 14px 0;
    border-bottom: 1px solid var(--rule);
}
#cc-root .cc-dl dt {
    margin: 0;
    font-weight: 800;
    color: var(--copper-2);
}
#cc-root .cc-dl dd {
    margin: 0;
    font-size: 0.93rem;
    line-height: 1.78;
    color: var(--mute);
}


/* ---------- FAQ ---------- */
#cc-root .cc-faq details {
    margin-bottom: 6px;
    border-bottom: 1px solid var(--rule);
}
#cc-root .cc-faq summary {
    padding: 14px 36px 14px 0;
    font-size: 1rem;
    font-weight: 700;
    color: var(--head);
    cursor: pointer;
    list-style: none;
    position: relative;
}
#cc-root .cc-faq summary::-webkit-details-marker { display: none; }
#cc-root .cc-faq summary::after {
    content: "+";
    position: absolute;
    right: 0;
    top: 12px;
    color: var(--copper);
    font-weight: 800;
}
#cc-root .cc-faq details[open] summary::after { content: "–"; }
#cc-root .cc-faq details p {
    margin: 0;
    padding: 0 0 16px;
    font-size: 0.96rem;
    line-height: 1.9;
    color: #4a4036;
}


/* ---------- 푸터 (2열 콜로폰) ---------- */
#cc-root .cc-end {
    padding: 48px 0 120px;
    background: #1c1712;
    color: #cfc4b4;
}
#cc-root .cc-end a { color: #e8d3b8; }
#cc-root .cc-end-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 32px 40px;
    padding-bottom: 28px;
    border-bottom: 1px solid #3a3229;
}
#cc-root .cc-end-name {
    margin: 0 0 10px;
    font-family: var(--serif);
    font-size: 1.2rem;
    color: #f6efe3;
}
#cc-root .cc-end-blurb {
    margin: 0;
    max-width: 48ch;
    font-size: 0.88rem;
    line-height: 1.8;
    color: #a89886;
}
#cc-root .cc-end-links {
    margin: 0;
    padding: 0;
    list-style: none;
}
#cc-root .cc-end-links li { margin-bottom: 7px; }
#cc-root .cc-end-links a {
    font-size: 0.86rem;
    color: #cfc4b4;
}
#cc-root .cc-end-links a:hover { color: #f0c9a0; text-decoration: none; }
#cc-root .cc-end-disc {
    margin: 22px 0 18px;
    font-size: 0.78rem;
    line-height: 1.85;
    color: #8a7b6c;
}
#cc-root .cc-end-copy {
    margin: 0;
    font-size: 0.76rem;
    color: #7a6c5e;
}


/* ---------- 플로팅 배너 (위치·구조 유지, 색만 변경) ---------- */
#cc-root .bd-dock {
    position: fixed;
    right: 26px;
    bottom: 26px;
    z-index: 90;
    animation: bd-bob 4.2s ease-in-out infinite;
    pointer-events: none;
}
#cc-root .bd-dock > * { pointer-events: auto; }

#cc-root .bd-dock-glow {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    pointer-events: none;
}
#cc-root .bd-dock-glow::before,
#cc-root .bd-dock-glow::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    background: linear-gradient(115deg, #b45a2a 0%, #3d5c4a 48%, #c9a36a 100%);
    will-change: opacity, transform;
}
#cc-root .bd-dock-glow::before {
    inset: -3px;
    filter: blur(9px);
    opacity: 0.9;
    animation: bd-glow-rim 3.4s ease-in-out infinite;
}
#cc-root .bd-dock-glow::after {
    inset: -13px;
    filter: blur(26px);
    opacity: 0.5;
    animation: bd-glow-halo 3.4s ease-in-out infinite;
}

#cc-root .bd-dock-btn {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 13px;
    min-width: 310px;
    padding: 15px 22px;
    background: linear-gradient(135deg, #2a211b, #140f0c);
    border: 1px solid rgba(180, 90, 42, 0.55);
    border-radius: 999px;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    color: #fff;
    transition: transform 0.2s ease, border-color 0.2s ease;
}
#cc-root .bd-dock-btn:hover {
    text-decoration: none;
    transform: scale(1.03);
    border-color: rgba(201, 163, 106, 0.9);
}

#cc-root .bd-dock-dot {
    flex: none;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #c9a36a;
    box-shadow: 0 0 0 0 rgba(201, 163, 106, 0.7);
    animation: bd-dock-ping 2.1s ease-out infinite;
}

#cc-root .bd-dock-txt {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    gap: 1px;
    line-height: 1.35;
    white-space: nowrap;
}
#cc-root .bd-dock-txt b {
    font-size: 1.02rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #fff;
}
#cc-root .bd-dock-txt em {
    font-style: normal;
    font-size: 0.73rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: #e8c48a;
}

#cc-root .bd-dock-ico {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    color: #140f0c;
    background: linear-gradient(135deg, #c9a36a, #b45a2a);
    animation: bd-dock-slide 1.9s ease-in-out infinite;
}

@keyframes bd-bob {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-11px); }
}
@keyframes bd-glow-rim {
    0%, 100% { opacity: 0.6; }
    50%      { opacity: 1; }
}
@keyframes bd-glow-halo {
    0%, 100% { opacity: 0.3; transform: scale(0.985); }
    50%      { opacity: 0.62; transform: scale(1.02); }
}
@keyframes bd-dock-ping {
    0%   { box-shadow: 0 0 0 0 rgba(201, 163, 106, 0.65); }
    70%  { box-shadow: 0 0 0 11px rgba(201, 163, 106, 0); }
    100% { box-shadow: 0 0 0 0 rgba(201, 163, 106, 0); }
}
@keyframes bd-dock-slide {
    0%, 100% { transform: translateX(0); }
    50%      { transform: translateX(4px); }
}


/* ==========================================================================
   이미지 자리(플레이스홀더)
   ※ max-width / aspect-ratio / min-height 수치는 원본 그대로.
   ========================================================================== */
#cc-root .bm-ph {
    width: 100%;
    max-width: 930px;
    margin: 6px auto 42px;
    padding: 0;
}
#cc-root .cc-copy + .bm-ph { margin-top: 40px; }

#cc-root .bm-ph--wide { max-width: 930px; }
#cc-root .bm-ph--md   { max-width: 640px; }
#cc-root .bm-ph--sq   { max-width: 560px; }

#cc-root .bm-ph-box {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 15px;
    aspect-ratio: 930 / 620;
    padding: 28px 26px;
    background-color: #2a211b;
    background-image: repeating-linear-gradient(135deg,
        rgba(201, 163, 106, 0.08) 0 12px,
        rgba(255, 255, 255, 0) 12px 26px);
    border: 2px dashed #6a5644;
    border-radius: 8px;
}
#cc-root .bm-ph--wide .bm-ph-box { aspect-ratio: 930 / 360; }
#cc-root .bm-ph--md   .bm-ph-box { aspect-ratio: 640 / 420; }
#cc-root .bm-ph--sq   .bm-ph-box { aspect-ratio: 1 / 1; }

#cc-root .bm-ph-mark {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    color: #e8c48a;
    background: rgba(180, 90, 42, 0.18);
    border: 1px solid rgba(201, 163, 106, 0.4);
    border-radius: 8px;
}

#cc-root .bm-ph-file {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 800;
    color: #f6efe3;
}
#cc-root .bm-ph-file em {
    display: inline-block;
    margin-left: 9px;
    padding: 2px 9px;
    font-style: normal;
    font-size: 0.73rem;
    font-weight: 800;
    line-height: 1.7;
    color: #140f0c;
    background: #c9a36a;
    border-radius: 999px;
    vertical-align: 1px;
}

#cc-root .bm-ph-spec {
    display: grid;
    gap: 9px;
    max-width: 74ch;
    margin: 0;
    padding: 0;
}
#cc-root .bm-ph-spec > div {
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 10px;
}
#cc-root .bm-ph-spec dt {
    margin: 0;
    padding-top: 0.2em;
    font-size: 0.75rem;
    font-weight: 800;
    color: #e8c48a;
}
#cc-root .bm-ph-spec dd {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.7;
    color: #cfc4b4;
}
#cc-root .bm-ph-spec .bm-ph-copy {
    font-weight: 700;
    color: #f6efe3;
}

#cc-root .bm-ph figcaption {
    margin-top: 11px;
    font-size: 0.78rem;
    color: #6d6256;
    text-align: center;
}


/* ---------- 반응형 ---------- */
@media (max-width: 900px) {
    #cc-root .cc-headpair { grid-template-columns: 1fr; gap: 8px; }
    #cc-root .cc-end-grid { grid-template-columns: 1fr; }
    #cc-root .cc-dl div { grid-template-columns: 1fr; }
    #cc-root .cc-weeks { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    #cc-root .cc-inner { padding-inline: 16px; }
    #cc-root .cc-top-row { padding: 14px 16px; }
    #cc-root .cc-lead { padding: 32px 0 28px; }
    #cc-root .cc-slice { padding: 48px 0; }
    #cc-root h1 { max-width: none; }

    #cc-root .cc-end { padding: 36px 0 130px; }

    #cc-root .bm-ph { margin-bottom: 34px; }
    #cc-root .cc-copy + .bm-ph { margin-top: 32px; }
    #cc-root .bm-ph-box,
    #cc-root .bm-ph--wide .bm-ph-box,
    #cc-root .bm-ph--md .bm-ph-box,
    #cc-root .bm-ph--sq .bm-ph-box {
        aspect-ratio: auto;
        min-height: 300px;
        padding: 20px 16px;
        gap: 12px;
        border-radius: 14px;
    }
    #cc-root .bm-ph-mark { width: 38px; height: 38px; }
    #cc-root .bm-ph-file { font-size: 0.85rem; }
    #cc-root .bm-ph-spec dd { font-size: 0.86rem; }

    #cc-root .bd-dock {
        right: 14px;
        left: auto;
        bottom: 14px;
    }
    #cc-root .bd-dock-btn {
        min-width: 0;
        width: auto;
        padding: 11px 13px 11px 16px;
        gap: 9px;
    }
    #cc-root .bd-dock-txt b { font-size: 0.87rem; }
    #cc-root .bd-dock-txt em { font-size: 0.66rem; }
    #cc-root .bd-dock-ico { width: 28px; height: 28px; }
    #cc-root .bd-dock-glow::before { inset: -2px; filter: blur(7px); }
    #cc-root .bd-dock-glow::after { inset: -10px; filter: blur(20px); }
}

@media (prefers-reduced-motion: reduce) {
    #cc-root * {
        animation-duration: 0.01ms;
        transition-duration: 0.01ms;
    }
}

@media print {
    #cc-root { background: #fff; color: #000; }
    #cc-root .cc-top,
    #cc-root .cc-cta,
    #cc-root .bd-dock { display: none; }
}
