/* Styles for the rebuilt 서비스 비교 page (editing-services1.htm) only.
   Every rule is scoped to body.comparison-new so nothing leaks into the
   live site. Shared breadcrumb/tab-bar styles come from advance-editingnew.css. */

/* ---------- Intro band (Figma: Container:margin) ---------- */

.comparison-new .esn-intro {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 80px 0;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.28) 0%, rgba(255, 255, 255, 0) 100.89%),
        linear-gradient(180deg, rgba(250, 224, 223, 0.7) 0%, rgba(244, 236, 230, 0.7) 100.91%);
}

.comparison-new .esn-intro-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 15px;
}

.comparison-new .esn-intro-title {
    margin: 0;
    font-weight: 700;
    font-size: 44px;
    line-height: 54px;
    color: #212529;
    text-align: center;
}

.comparison-new .esn-intro-desc {
    margin: 0;
    font-size: 18px;
    line-height: 27px;
    color: #212529;
    text-align: center;
    word-break: keep-all;
}

@media only screen and (max-width: 767px) {
    .comparison-new .esn-intro {
        padding: 48px 0;
    }

    .comparison-new .esn-intro-title {
        font-size: 28px;
        line-height: 36px;
    }

    .comparison-new .esn-intro-desc {
        font-size: 16px;
        line-height: 24px;
    }
}

/* ---------- Service comparison table (Figma: Container) ---------- */

.comparison-new .esn-compare {
    padding: 80px 0;
    /* solid white on top, fading down into the soft pink/white/blue/pink blend */
    background:
        linear-gradient(180deg, #FFFFFF 0%, #FFFFFF 30%, rgba(255, 255, 255, 0) 75%),
        linear-gradient(105.77deg, rgba(250, 224, 223, 0.8) 0%, #FFFFFF 38%, rgba(235, 245, 255, 0.9) 62%, rgba(250, 224, 223, 0.5) 92%),
        #FFFFFF;
}

.comparison-new .esn-compare-inner {
    display: flex;
    flex-direction: column;
    gap: 50px;
    width: 100%;
    max-width: 1086px;
    margin: 0 auto;
    padding: 0 15px;
}

/* overflow must stay visible at every width or the sticky table header
   (position: sticky) stops working — like enago.jp/comparison the table
   reflows to fit instead of scrolling inside a box (tablet: compressed
   columns, mobile: stacked rows — see the media queries at the bottom) */
.comparison-new .esn-table-scroll {
    overflow: visible;
}

.comparison-new .esn-table {
    width: 100%;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 0;
    margin: 0;
}

.comparison-new .esn-col-label {
    width: 40%;
}

.comparison-new .esn-col-service {
    width: 20%;
}

/* --- header row --- */

.comparison-new .esn-table-main thead th {
    height: 152px;
    padding: 0;
    /* solid white (not transparent) so rows can't show through while stuck */
    background: #FFFFFF;
    border: 0;
    border-bottom: 1px solid #C6C5C5;
    /* stays pinned below the service tab bar while scrolling the table
       (like enago.jp/comparison); offset synced by the inline script */
    position: -webkit-sticky;
    position: sticky;
    top: var(--esn-sticky-top, 0px);
    z-index: 50;
}

.comparison-new .esn-th-label {
    vertical-align: bottom;
}

.comparison-new .esn-th-label-box {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 67px;
    background: #F4ECE6;
    border: 1px solid #C6C5C5;
    border-bottom: 0;
    /* the 탑 임팩트 cell's border-left draws this edge — keeping both
       doubles the line into a 2px border */
    border-right: 0;
    border-radius: 5px 0 0 0;
    font-weight: 700;
    font-size: 30px;
    line-height: 45px;
    color: #212529;
    text-align: center;
}

.comparison-new .esn-th-service {
    position: relative;
    overflow: hidden;
    vertical-align: top;
    text-align: center;
    border-top: 1px solid #C6C5C5 !important;
    border-right: 1px solid #C6C5C5 !important;
}

.comparison-new .esn-th-tie {
    background: #DFF1FD !important;
    border-left: 1px solid #C6C5C5 !important;
    border-radius: 5px 0 0 0;
}

.comparison-new .esn-th-ae {
    background: #ECF7FE !important;
}

.comparison-new .esn-th-ne {
    background: #F6FBFF !important;
    border-radius: 0 5px 0 0;
}

.comparison-new .esn-ribbon {
    position: absolute;
    top: 0;
    left: 0;
    width: 97px;
    height: 95px;
    pointer-events: none;
}

.comparison-new .esn-th-icon {
    display: block;
    margin: 24px auto 10px;
    /* icons have different intrinsic heights (30/26/36px) — give them all the
       same box so the service names below line up across the three columns */
    height: 36px;
    object-fit: contain;
    object-position: center bottom;
}

.comparison-new .esn-th-name {
    display: block;
    font-weight: 700;
    font-size: 24px;
    line-height: 36px;
    color: #212529;
    text-align: center;
}

/* --- feature rows --- */

.comparison-new .esn-tbody-features tr:nth-child(odd) {
    background: #FFFFFF;
}

.comparison-new .esn-tbody-features tr:nth-child(even) {
    background: #FAF8F6;
}

.comparison-new .esn-tbody-features th,
.comparison-new .esn-tbody-features td {
    height: 88px;
    padding: 10px;
    vertical-align: middle;
    border: 0;
}

.comparison-new .esn-feature {
    padding-left: 48px !important;
    font-weight: 700;
    font-size: 18px;
    line-height: 27px;
    color: #000000;
    text-align: left;
    word-break: keep-all;
    border-left: 1px solid #C6C5C5 !important;
}

.comparison-new .esn-cell {
    position: relative;
    text-align: center;
}

.comparison-new .esn-cell:last-child {
    border-right: 1px solid #C6C5C5 !important;
}

/* inset vertical dividers between columns */
.comparison-new .esn-cell::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 1px;
    background: #C6C5C5;
}

.comparison-new .esn-tbody-features tr:last-child th,
.comparison-new .esn-tbody-features tr:last-child td {
    border-bottom: 1px solid #C6C5C5 !important;
}

/* --- 사후 지원 서비스 band --- */

.comparison-new .esn-tbody-subhead th,
.comparison-new .esn-tbody-subhead td {
    height: 66px;
    padding: 0;
    background: transparent;
    border: 0;
    vertical-align: middle;
}

.comparison-new .esn-subhead {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 66px;
    margin: 0;
    background: #F4ECE6;
    border-left: 1px solid #C6C5C5;
    border-right: 1px solid #C6C5C5;
    font-weight: 700;
    font-size: 30px;
    line-height: 45px;
    color: #212529;
    text-align: center;
}

/* --- support rows --- */

.comparison-new .esn-tbody-support tr:nth-child(odd) {
    background: #FFFFFF;
}

.comparison-new .esn-tbody-support tr:nth-child(even) {
    background: #FAF8F6;
}

.comparison-new .esn-tbody-support th,
.comparison-new .esn-tbody-support td {
    /* rows size to their content (4 / 2 / 1 bullets) like enago.jp */
    padding: 28px 10px;
    vertical-align: middle;
    border: 0;
    border-bottom: 1px solid #C6C5C5 !important;
}

.comparison-new .esn-tbody-support tr:first-child th,
.comparison-new .esn-tbody-support tr:first-child td {
    border-top: 1px solid #C6C5C5 !important;
}

.comparison-new .esn-support {
    /* Figma: icon slot 14px from the cell edge, text block at 88px (14 + 64 + 10) —
       no right padding so the title fits on one line */
    padding: 28px 0 28px 14px !important;
    text-align: left;
    border-left: 1px solid #C6C5C5 !important;
}

.comparison-new .esn-support-inner {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

/* fixed-width icon slot so the text blocks align across rows
   even though the badges have different widths */
.comparison-new .esn-support-icon {
    flex: none;
    display: flex;
    justify-content: center;
    width: 64px;
    /* centers the 42px badge on the title's 27px first line */
    margin-top: -8px;
}

.comparison-new .esn-support-icon img {
    display: block;
}

.comparison-new .esn-support-text {
    flex: 1;
    min-width: 0;
}

.comparison-new .esn-support-text h3 {
    /* !important: a shared stylesheet forces margin-top: 40px on h3 */
    margin: 0 0 12px !important;
    font-weight: 700;
    font-size: 18px;
    line-height: 27px;
    color: #000000;
    word-break: keep-all;
}

.comparison-new .esn-support-text ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.comparison-new .esn-support-text li {
    display: flex;
    /* top-aligned so the square marker stays on the first line when text wraps */
    align-items: flex-start;
    gap: 10px;
    padding: 4px 0;
    font-weight: 400;
    font-size: 16px;
    line-height: 24px;
    color: #000000;
    word-break: keep-all;
}

.comparison-new .esn-support-text li::before {
    content: '';
    flex: none;
    width: 8px;
    height: 8px;
    /* (24px line-height - 8px square) / 2 — centers on the first text line */
    margin-top: 8px;
    background: #FFFFFF;
    border: 2px solid #D52B1E;
}

.comparison-new .esn-free {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.comparison-new .esn-free em {
    font-style: normal;
    font-weight: 400;
    font-size: 16px;
    line-height: 24px;
    color: #000000;
}

/* --- CTA --- */

.comparison-new .esn-cta {
    text-align: center;
}

/* ---------- Tablet (768–991px): compressed desktop table ----------
   The percentage columns simply narrow to fit the viewport (no inner
   scrollbox — that would break the sticky header), so only the type
   sizes need to come down. */

@media only screen and (max-width: 991px) {
    .comparison-new .esn-table-main thead th {
        height: 132px;
    }

    .comparison-new .esn-th-label-box {
        font-size: 22px;
        line-height: 33px;
        height: 56px;
    }

    .comparison-new .esn-th-name {
        font-size: 18px;
        line-height: 26px;
    }

    .comparison-new .esn-ribbon {
        width: 72px;
        height: 70px;
    }

    .comparison-new .esn-subhead {
        font-size: 22px;
        line-height: 33px;
        height: 56px;
    }

    .comparison-new .esn-feature {
        padding-left: 20px !important;
        font-size: 16px;
        line-height: 24px;
    }

    .comparison-new .esn-support-text h3 {
        font-size: 16px;
        line-height: 24px;
    }

    .comparison-new .esn-support-text li {
        font-size: 14px;
        line-height: 21px;
    }

    .comparison-new .esn-support-text li::before {
        margin-top: 6px;
    }
}

/* ---------- Mobile (≤767px): stacked rows like enago.jp/comparison ----------
   The table flattens into block flow: the sticky header shows the three
   service columns with the section label band under them, and every row
   becomes a full-width label band with its three value cells beneath it. */

@media only screen and (max-width: 767px) {
    .comparison-new .esn-compare {
        padding: 48px 0;
    }

    .comparison-new .esn-compare-inner {
        gap: 32px;
    }

    /* flatten the table into block/flex flow (enago.jp builds this from divs) */
    .comparison-new .esn-table,
    .comparison-new .esn-table thead,
    .comparison-new .esn-table tbody,
    .comparison-new .esn-table tr,
    .comparison-new .esn-table th,
    .comparison-new .esn-table td {
        display: block;
    }

    .comparison-new .esn-table colgroup,
    .comparison-new .esn-table td.esn-subhead-void,
    .comparison-new .esn-ribbon {
        display: none;
    }

    /* --- sticky header: the whole thead pins as one block --- */
    .comparison-new .esn-table-main thead {
        position: -webkit-sticky;
        position: sticky;
        top: var(--esn-sticky-top, 0px);
        z-index: 50;
        background: #FFFFFF;
    }

    .comparison-new .esn-table-main thead tr {
        display: flex;
        flex-wrap: wrap;
    }

    .comparison-new .esn-table-main thead th {

        position: static;
        height: auto;
        border-bottom: 0;
    }

    /* label band drops below the three service columns (JP: order swap) */
    .comparison-new .esn-th-label {
        order: 2;
        width: 100%;
    }

    .comparison-new .esn-th-label-box {
        height: auto;
        justify-content: flex-start;
        padding: 10px 15px;
        border: 1px solid #C6C5C5;
        border-radius: 0;
        font-size: 18px;
        line-height: 27px;
        text-align: left;
    }

    .comparison-new .esn-th-service {
        order: 1;
        width: 33.3333%;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 10px 4px;
        overflow: visible;
    }

    .comparison-new .esn-th-icon {
        margin: 8px auto 4px;
    }

    .comparison-new .esn-th-name {
        font-size: 13px;
        line-height: 19px;
    }

    /* --- rows: full-width label band + three value cells under it --- */
    .comparison-new .esn-tbody-features tr,
    .comparison-new .esn-tbody-support tr {
        display: flex;
        flex-wrap: wrap;
    }

    /* JP mobile drops the row striping: label bands white, value cells tinted */
    .comparison-new .esn-tbody-features tr:nth-child(odd),
    .comparison-new .esn-tbody-features tr:nth-child(even),
    .comparison-new .esn-tbody-support tr:nth-child(odd),
    .comparison-new .esn-tbody-support tr:nth-child(even) {
        background: #FFFFFF;
    }

    .comparison-new .esn-tbody-features th,
    .comparison-new .esn-tbody-features td {
        height: auto;
    }

    .comparison-new .esn-feature {
        width: 100%;
        padding: 12px 15px !important;
        font-size: 16px;
        line-height: 24px;
        border-left: 1px solid #C6C5C5 !important;
        border-right: 1px solid #C6C5C5 !important;
    }

    /* the label band never carries its own bottom border — the cells' top
       border draws that line (avoids doubling on the last feature row) */
    .comparison-new .esn-tbody-features tr:last-child th {
        border-bottom: 0 !important;
    }

    .comparison-new .esn-cell {
        width: 33.3333%;
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 64px;
        padding: 14px 10px;
        background: #FAF8F6;
        border-top: 1px solid #C6C5C5 !important;
        border-bottom: 1px solid #C6C5C5 !important;
    }

    /* the inset column dividers become full-height lines; the first cell's
       divider doubles as the row's left edge */
    .comparison-new .esn-cell::before {
        top: 0;
        bottom: 0;
    }

    /* --- 사후 지원 서비스 band --- */
    .comparison-new .esn-tbody-subhead th {
        height: auto;
        width: 100%;
    }

    .comparison-new .esn-subhead {
        height: auto;
        justify-content: flex-start;
        padding: 10px 15px;
        font-size: 18px;
        line-height: 27px;
        text-align: left;
    }

    /* --- support rows --- */
    .comparison-new .esn-tbody-support th,
    .comparison-new .esn-tbody-support td {
        padding: 14px 10px;
    }

    .comparison-new .esn-support {
        width: 100%;
        padding: 14px 15px !important;
        border-left: 1px solid #C6C5C5 !important;
        border-right: 1px solid #C6C5C5 !important;
    }

    .comparison-new .esn-tbody-support th.esn-support {
        border-bottom: 0 !important;
    }

    .comparison-new .esn-support-icon {
        width: 48px;
        margin-top: -4px;
    }

    .comparison-new .esn-support-icon img {
        max-width: 48px;
        height: auto;
    }

    .comparison-new .esn-support-text h3 {
        margin-bottom: 8px !important;
        font-size: 16px;
        line-height: 24px;
    }

    .comparison-new .esn-support-text li {
        font-size: 14px;
        line-height: 21px;
        padding: 3px 0;
    }

    .comparison-new .esn-support-text li::before {
        margin-top: 6px;
    }

    .comparison-new .esn-free {
        gap: 6px;
    }

    .comparison-new .esn-free em {
        font-size: 14px;
        line-height: 21px;
    }
}