/* 위탁판매 프로세스 도식 — 공개 페이지용 (가독성 보강) */
.cs-shell {
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 18%, #f1f5f9 100%);
}
.cs-process.cti-process-wrap {
    --cti-navy: #0b2545;
    --cti-blue: #1b5e9c;
    --cti-gold: #b8956c;
    --cti-bg: transparent;
    --cti-card: #ffffff;
    --cti-line: #e2e8f0;
    --cti-text: #0f172a;
    --cti-sub: #475569;
    --cti-soft: #f1f5f9;
    --cti-line1: #1b5e9c;
    --cti-line2: #2e8b57;
    --cti-line3: #b8956c;
    font-size: 15px;
    line-height: 1.6;
    padding: 2rem 0 3rem;
}
.cs-process .cti-header h1 {
    font-family: "Noto Serif KR", "Noto Sans KR", serif;
    font-size: clamp(1.35rem, 3vw, 1.65rem);
}
.cs-process .cti-summary {
    border-radius: 1rem;
    box-shadow: 0 20px 48px -32px rgba(11, 37, 69, 0.35);
}
.cs-process .cti-summary .cti-summary-main {
    font-size: 1.05rem;
}
.cs-process .cti-summary .cti-stat-value {
    font-size: 1.25rem;
}
.cs-process .cti-node {
    min-width: 118px;
    transition: border-color 0.45s ease, box-shadow 0.45s ease;
}
.cs-process .cti-flow-row {
    border-radius: 0.85rem;
    transition: box-shadow 0.45s ease;
}
.cs-process .cti-flow-row:hover {
    box-shadow: 0 12px 32px -24px rgba(15, 23, 42, 0.12);
}

/* §1 흐름도 — 가독성 + 모션 */
.cs-shell .cs-process.cti-process-wrap .cti-flow-grid {
    gap: 1.25rem;
}
.cs-shell .cs-process.cti-process-wrap .cti-flow-row {
    padding: 1.25rem 1.35rem 1.5rem;
    background: #fff;
    box-shadow: 0 10px 36px -28px rgba(11, 37, 69, 0.14);
    transition: box-shadow 0.45s ease, border-color 0.45s ease, transform 0.45s ease;
}
.cs-shell .cs-process.cti-process-wrap .cti-flow-row.is-flow-visible {
    border-color: rgba(226, 232, 240, 0.95);
}
.cs-shell .cs-process.cti-process-wrap .cti-line-badge {
    font-size: 0.875rem;
}
.cs-shell .cs-process.cti-process-wrap .cti-line-tag {
    font-size: 0.75rem;
    line-height: 1.45;
    max-width: 22rem;
}
.cs-shell .cs-process.cti-process-wrap .cti-node {
    min-width: 7.75rem;
    padding: 0.85rem 0.75rem;
    box-shadow: 0 4px 14px -10px rgba(15, 23, 42, 0.12);
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}
.cs-shell .cs-process.cti-process-wrap .cti-node:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px -14px rgba(15, 23, 42, 0.18);
}
.cs-shell .cs-process.cti-process-wrap .cti-node-title {
    font-size: 0.875rem;
}
.cs-shell .cs-process.cti-process-wrap .cti-node-sub {
    font-size: 0.8125rem;
    line-height: 1.5;
}
.cs-shell .cs-process.cti-process-wrap .cti-arrow {
    min-width: 5.75rem;
    padding: 0 0.45rem;
}
.cs-shell .cs-process.cti-process-wrap .cti-arrow-label {
    font-size: 0.75rem;
    line-height: 1.35;
}
.cs-shell .cs-process.cti-process-wrap .cti-arrow-amt {
    font-size: 0.6875rem;
    line-height: 1.4;
    margin-top: 0.15rem;
}
.cs-shell .cs-process.cti-process-wrap .cti-arrow {
    position: relative;
    z-index: 3;
}
.cs-shell .cs-process.cti-process-wrap .cti-node {
    position: relative;
    z-index: 1;
}
.cs-shell .cs-process.cti-process-wrap .cti-node:hover {
    z-index: 2;
}
.cs-shell .cs-process.cti-process-wrap .cti-arrow-line {
    height: 3px;
    border-radius: 2px;
    overflow: visible;
    transform: none;
}
.cs-shell .cs-process.cti-process-wrap .cti-flow-chain {
    gap: 0.15rem;
    padding-bottom: 0.35rem;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}
.cs-shell .cs-process.cti-process-wrap .cs-struct-line {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    background: rgba(241, 245, 249, 0.85);
    border: 1px solid #e2e8f0;
}

/* 스크롤 등장 — CORE + 3라인 */
.cs-flow-reveal {
    opacity: 0;
    transform: translateY(18px);
    transition:
        opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1),
        transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}
.cs-flow-reveal.is-flow-visible {
    opacity: 1;
    transform: translateY(0);
}
.cs-flow-part {
    opacity: 0;
    transform: translateY(10px);
    transition:
        opacity 0.5s cubic-bezier(0.22, 1, 0.36, 1),
        transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
    transition-delay: calc(0.12s + var(--cs-flow-i, 0) * 0.07s);
}
.is-flow-visible .cs-flow-part,
.cti-summary.is-flow-visible .cs-flow-part {
    opacity: 1;
    transform: translateY(0);
}
.cti-summary.is-flow-visible {
    animation: cs-summary-glow 1.2s ease 0.1s both;
}
@keyframes cs-summary-glow {
    from {
        box-shadow: 0 20px 48px -32px rgba(11, 37, 69, 0.35);
    }
    to {
        box-shadow: 0 24px 56px -28px rgba(27, 94, 156, 0.28);
    }
}
.is-flow-visible .cti-line-badge .cti-dot {
    animation: cs-dot-pulse 2s ease-in-out infinite;
}
@keyframes cs-dot-pulse {
    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.35);
        opacity: 0.75;
    }
}
/* transform 대신 clip-path — 노드 hover 시 가로 연결선이 사라지는 현상 방지 */
.is-flow-visible .cti-arrow-line {
    clip-path: inset(0 100% 0 0);
    animation: cs-arrow-draw 0.55s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: calc(0.08s + var(--cs-flow-i, 0) * 0.09s);
}
.is-flow-visible .cti-flow-row:hover .cti-arrow-line,
.is-flow-visible .cti-node:hover ~ .cti-arrow .cti-arrow-line,
.is-flow-visible .cti-node:hover + .cti-arrow .cti-arrow-line {
    clip-path: inset(0 0 0 0);
}
.is-flow-visible .cti-arrow-line::after {
    opacity: 0;
    animation: cs-arrow-head 0.35s ease forwards;
    animation-delay: calc(0.35s + var(--cs-flow-i, 0) * 0.09s);
}
@keyframes cs-arrow-draw {
    to {
        clip-path: inset(0 0 0 0);
    }
}
@keyframes cs-arrow-head {
    to {
        opacity: 1;
    }
}
.line-1.is-flow-visible .cti-arrow-line {
    background: linear-gradient(90deg, var(--cti-line1), rgba(27, 94, 156, 0.45));
}
.line-2.is-flow-visible .cti-arrow-line {
    background: linear-gradient(90deg, var(--cti-line2), rgba(46, 139, 87, 0.45));
}
.line-3.is-flow-visible .cti-arrow-line {
    background: linear-gradient(90deg, var(--cti-line3), rgba(184, 149, 108, 0.55));
}
.cs-process .cti-node-title {
    font-size: 0.8125rem;
}
.cs-process .cti-node-sub {
    font-size: 0.75rem;
    color: #64748b;
}
.cs-process .cti-section-desc {
    font-size: 0.9375rem;
    color: #334155;
    line-height: 1.65;
    margin: 0.625rem 0 1.75rem;
    max-width: 52rem;
}
/* § 제목 하단 구분선 — hover/레이어 영향으로 사라지지 않도록 pseudo 고정 */
.cs-shell .cs-process.cti-process-wrap .cti-section-title {
    position: relative;
    border-bottom: none;
    padding-bottom: 0.65rem;
    isolation: isolate;
}
.cs-shell .cs-process.cti-process-wrap .cti-section-title::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    border-radius: 1px;
    background: linear-gradient(90deg, var(--cti-line1) 0%, var(--cti-line) 55%, transparent 100%);
    pointer-events: none;
    z-index: 1;
}
.cs-cta-bar {
    border-top: 1px solid #e2e8f0;
    padding: 2rem 0 2.5rem;
    gap: 1.125rem;
}
.cs-cta-bar .cs-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    min-height: 3.375rem;
    padding: 1.125rem 2.75rem;
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.35;
    letter-spacing: 0.01em;
    white-space: nowrap;
    border-radius: 9999px;
    text-decoration: none;
    transition: transform 0.35s ease, box-shadow 0.35s ease, background 0.35s ease, border-color 0.35s ease;
}
.cs-cta-bar .cs-cta:hover {
    transform: translateY(-2px);
}
.cs-cta-bar .cs-cta--primary {
    background: rgb(15 23 42);
    color: #fff;
    border: 1px solid rgb(15 23 42);
    box-shadow: 0 8px 20px -12px rgba(15, 23, 42, 0.35);
}
.cs-cta-bar .cs-cta--primary:hover {
    background: rgb(30 41 59);
}
.cs-cta-bar .cs-cta--outline {
    background: #fff;
    color: rgb(30 41 59);
    border: 1px solid rgb(203 213 225);
}
.cs-cta-bar .cs-cta--outline:hover {
    border-color: rgba(184, 149, 108, 0.5);
}
.cs-cta-bar .cs-cta--soft {
    background: rgb(248 250 252);
    color: rgb(51 65 85);
    border: 1px solid rgb(226 232 240);
}
.cs-cta-bar .cs-cta--soft:hover {
    background: #fff;
}
@media (max-width: 640px) {
    .cs-cta-bar .cs-cta {
        width: 100%;
        max-width: 22rem;
        white-space: normal;
        text-align: center;
        padding: 1rem 1.5rem;
        min-height: 3.25rem;
    }
}

/* §2 STEP 카드 */
.cs-process .cti-steps {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.75rem;
}
.cs-process .cti-step {
    background: var(--cti-card);
    border: 1px solid var(--cti-line);
    border-radius: 0.75rem;
    padding: 1rem 0.9rem;
    transition: border-color 0.45s ease, box-shadow 0.45s ease, transform 0.45s ease;
}
.cs-process .cti-step:hover {
    border-color: rgba(27, 94, 156, 0.35);
    box-shadow: 0 10px 28px -22px rgba(15, 23, 42, 0.12);
    transform: translateY(-3px);
}
.cs-process .cti-step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    background: var(--cti-navy);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 0.65rem;
}
.cs-process .cti-step-title {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--cti-navy);
    margin-bottom: 0.4rem;
    line-height: 1.4;
}
.cs-process .cti-step-actor {
    display: inline-block;
    font-size: 0.6875rem;
    color: var(--cti-blue);
    background: #eaf2fb;
    padding: 0.15rem 0.5rem;
    border-radius: 9999px;
    margin-bottom: 0.5rem;
}
.cs-process .cti-step-detail {
    font-size: 0.8125rem;
    color: var(--cti-sub);
    line-height: 1.55;
}
.cs-process .cti-step-detail ul {
    margin: 0.25rem 0 0;
    padding-left: 1rem;
}
.cs-process .cti-step-detail li {
    margin-bottom: 0.25rem;
}

/* §3 손익 테이블 */
.cs-process .cti-table-wrap {
    background: var(--cti-card);
    border: 1px solid var(--cti-line);
    border-radius: 0.75rem;
    overflow-x: auto;
}
.cs-process .cti-table {
    width: 100%;
    min-width: 32rem;
    border-collapse: collapse;
    font-size: 0.875rem;
}
.cs-process .cti-table thead th {
    background: var(--cti-navy);
    color: #fff;
    font-weight: 600;
    text-align: left;
    padding: 0.75rem 1rem;
    font-size: 0.8125rem;
}
.cs-process .cti-table tbody td {
    padding: 0.7rem 1rem;
    border-bottom: 1px solid var(--cti-line);
    color: var(--cti-text);
}
.cs-process .cti-table tbody tr:last-child td {
    border-bottom: none;
}
.cs-process .cti-table tbody tr.cti-tr-total td {
    background: #fff8e6;
    font-weight: 700;
    color: var(--cti-navy);
}
/* 제조사 실수령액 [F] — 제조사 관점 핵심 수치 강조 */
.cs-process .cti-table tbody tr.cti-tr-mfg-highlight td {
    background: linear-gradient(90deg, #0b2545 0%, #153a63 55%, #1b5e9c 100%);
    color: #fff;
    font-weight: 700;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: inset 4px 0 0 #e8c88a;
}
.cs-process .cti-table tbody tr.cti-tr-mfg-highlight .cti-amt {
    color: #f5d78e;
    font-size: 1.0625rem;
    font-weight: 800;
    letter-spacing: 0.02em;
}
.cs-process .cti-table .cti-amt {
    text-align: right;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
.cs-process .cti-table .cti-minus {
    color: #d9534f;
}

/* §3 백화점 가격 구조 참고 — 본문·손익표와 동일 톤 */
.cs-process .cs-sec3-price-note {
    margin-top: 1.25rem;
    padding: 1.15rem 1.25rem 1.2rem;
    border-radius: 0.75rem;
    border: 1px solid var(--cti-line);
    background: var(--cti-card);
    box-shadow: 0 10px 36px -28px rgba(11, 37, 69, 0.12);
    font-size: 0.875rem;
    line-height: 1.6;
    color: var(--cti-sub);
}
.cs-process .cs-sec3-price-lead {
    margin: 0 0 1rem;
    font-size: 0.9375rem;
    font-weight: 600;
    color: #334155;
    line-height: 1.65;
}
.cs-process .cs-sec3-price-lead strong {
    color: var(--cti-navy);
    font-weight: 700;
}
.cs-process .cs-sec3-price-h {
    margin: 1rem 0 0.5rem;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--cti-navy);
    letter-spacing: 0.01em;
}
.cs-process .cs-sec3-price-h--inline {
    margin-top: 0;
    margin-bottom: 0.4rem;
}
.cs-process .cs-sec3-mini-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--cti-line);
    border-radius: 0.5rem;
    background: #fff;
}
.cs-process .cs-sec3-mini-table {
    width: 100%;
    min-width: 28rem;
    border-collapse: collapse;
    font-size: 0.8125rem;
}
.cs-process .cs-sec3-mini-table thead th {
    background: #f1f5f9;
    color: var(--cti-text);
    font-weight: 600;
    text-align: left;
    padding: 0.6rem 0.85rem;
    border-bottom: 1px solid var(--cti-line);
    font-size: 0.8125rem;
}
.cs-process .cs-sec3-mini-table tbody td {
    padding: 0.65rem 0.85rem;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: top;
    color: var(--cti-text);
}
.cs-process .cs-sec3-mini-table tbody tr:last-child td {
    border-bottom: none;
}
.cs-process .cs-sec3-mini-table tbody tr.cs-sec3-mini-total td {
    background: #fff8e6;
    font-weight: 700;
    color: var(--cti-navy);
    font-size: 0.875rem;
}
.cs-process .cs-sec3-mini-amt {
    text-align: right;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
.cs-process .cs-sec3-mini-stack {
    color: #64748b;
    font-size: 0.75rem;
    font-style: normal;
}
.cs-process .cs-sec3-price-list {
    margin: 0.35rem 0 0;
    padding-left: 1.15rem;
    list-style: disc;
    font-size: 0.8125rem;
    line-height: 1.65;
}
.cs-process .cs-sec3-price-list li {
    margin-bottom: 0.35rem;
}
.cs-process .cs-sec3-price-list li strong {
    color: #334155;
    font-weight: 600;
}
.cs-process .cs-sec3-price-em {
    color: var(--cti-blue);
    font-weight: 700;
}
.cs-process .cs-sec3-price-callout {
    margin-top: 1rem;
    padding: 0.85rem 1rem;
    border-radius: 0.5rem;
    border-left: 3px solid var(--cti-gold);
    background: rgba(184, 149, 108, 0.08);
}
.cs-process .cs-sec3-price-callout-p {
    margin: 0;
    font-size: 0.8125rem;
    line-height: 1.65;
    color: var(--cti-sub);
}
.cs-process .cs-sec3-price-callout-p strong {
    color: var(--cti-navy);
    font-weight: 600;
}
.cs-process .cs-sec3-price-callout-p em {
    font-style: normal;
    font-weight: 600;
    color: var(--cti-navy);
}
@media (max-width: 640px) {
    .cs-process .cs-sec3-price-note {
        padding: 1rem;
        font-size: 0.8125rem;
    }
    .cs-process .cs-sec3-price-lead {
        font-size: 0.875rem;
    }
}

/* §4 리스크 */
.cs-process .cti-risk-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.85rem;
}
.cs-process .cti-risk-card {
    background: var(--cti-card);
    border: 1px solid var(--cti-line);
    border-top: 3px solid #d9534f;
    border-radius: 0.5rem;
    padding: 1rem 1.1rem;
    transition: border-color 0.45s ease, box-shadow 0.45s ease, transform 0.45s ease;
}
.cs-process .cti-risk-card:hover {
    box-shadow: 0 10px 26px -20px rgba(15, 23, 42, 0.1);
    transform: translateY(-2px);
}
.cs-process .cti-risk-card.lvl-mid {
    border-top-color: var(--cti-gold);
}
.cs-process .cti-risk-card.lvl-low {
    border-top-color: var(--cti-blue);
}
.cs-process .cti-risk-level {
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: #d9534f;
    margin-bottom: 0.35rem;
}
.cs-process .lvl-mid .cti-risk-level {
    color: var(--cti-gold);
}
.cs-process .lvl-low .cti-risk-level {
    color: var(--cti-blue);
}
.cs-process .cti-risk-title {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--cti-navy);
    margin-bottom: 0.35rem;
    line-height: 1.4;
}
.cs-process .cti-risk-body {
    font-size: 0.8125rem;
    color: var(--cti-sub);
    line-height: 1.55;
}

.cs-process .cti-footer {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--cti-line);
    font-size: 0.75rem;
    color: var(--cti-sub);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* 스크롤 등장 */
.cs-reveal {
    opacity: 0;
    transform: translateY(12px);
    transition:
        opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1),
        transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    transition-delay: calc(var(--cs-i, 0) * 0.07s);
}
.cs-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
    .cs-reveal,
    .cs-flow-reveal,
    .cs-flow-part {
        opacity: 1;
        transform: none;
        transition: none;
        animation: none;
    }
    .is-flow-visible .cti-arrow-line,
    .is-flow-visible .cti-arrow-line::after {
        clip-path: none;
        opacity: 1;
        animation: none;
    }
    .cti-summary.is-flow-visible {
        animation: none;
    }
    .is-flow-visible .cti-line-badge .cti-dot {
        animation: none;
    }
    .cs-process .cti-step:hover,
    .cs-process .cti-risk-card:hover,
    .cs-shell .cs-process.cti-process-wrap .cti-node:hover {
        transform: none;
    }
}
@media (max-width: 1024px) {
    .cs-process.cti-process-wrap .cti-summary {
        grid-template-columns: 1fr 1fr;
    }
    .cs-process .cti-steps {
        grid-template-columns: repeat(3, 1fr);
    }
    .cs-process .cti-risk-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 640px) {
    .cs-process.cti-process-wrap {
        padding: 1.25rem 0 2rem;
    }
    .cs-process.cti-process-wrap .cti-summary {
        grid-template-columns: 1fr;
    }
    .cs-process .cti-flow-chain {
        flex-direction: column;
        align-items: stretch;
    }
    .cs-process .cti-arrow {
        min-width: 0;
        padding: 0.35rem 0;
    }
    .cs-process .cti-arrow .cti-arrow-line {
        width: 2px;
        height: 1.25rem;
        margin: 0 auto;
    }
    .cs-process .cti-arrow .cti-arrow-line::after {
        right: auto;
        left: 50%;
        top: 100%;
        transform: translate(-50%, 0);
        border-left: 5px solid transparent;
        border-right: 5px solid transparent;
        border-top: 7px solid var(--cti-sub);
        border-bottom: none;
    }
    .is-flow-visible .cti-arrow-line {
        clip-path: inset(0 0 100% 0);
        animation-name: cs-arrow-draw-v;
    }
    @keyframes cs-arrow-draw-v {
        to {
            clip-path: inset(0 0 0 0);
        }
    }
    .cs-process .line-1 .cti-arrow .cti-arrow-line::after {
        border-top-color: var(--cti-line1);
    }
    .cs-process .line-2 .cti-arrow .cti-arrow-line::after {
        border-top-color: var(--cti-line2);
    }
    .cs-process .line-3 .cti-arrow .cti-arrow-line::after {
        border-top-color: var(--cti-line3);
    }
    .cs-process .cti-steps {
        grid-template-columns: 1fr;
    }
    .cs-process .cti-risk-grid {
        grid-template-columns: 1fr;
    }
    .cs-process .cti-footer {
        flex-direction: column;
    }
}
