/* ==========================================================================
   JETCO /beta : 자료실 · 자주 묻는 질문 (fq-)  v2 팔레트
   즉시 검색 + 분류 칩 + 아코디언 / 고정 사이드 문의 패널 / 데이터 복구와 포렌식 비교
   색은 site.css 토큰만 사용 (--signal: 밝은 영역 인디고 · 어두운 영역 옐로우)
   ========================================================================== */

.fq-section { position: relative; isolation: isolate; padding-top: clamp(64px, 7vw, 112px); }
/* 섹션 뒤 키네틱 아웃라인 타이포 */
.fq-kinetic { position: absolute; z-index: -1; left: 0; right: 0; top: clamp(14px, 2.4vw, 36px); overflow: hidden; white-space: nowrap; pointer-events: none; }
.fq-kinetic span {
    display: inline-block; padding-left: 4vw;
    font-size: clamp(84px, 14vw, 236px); font-weight: 800; line-height: 1; letter-spacing: -0.06em;
    color: transparent; -webkit-text-stroke: 1.5px rgba(46, 48, 146, .11);
}
.fq-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: clamp(32px, 5vw, 88px); align-items: start; }
.fq-main { min-width: 0; }

/* ---------- 1. 검색 ---------- */
.fq-search {
    position: relative; isolation: isolate; overflow: hidden;
    display: flex; align-items: center; gap: 10px;
    height: clamp(64px, 6vw, 82px); padding: 0 18px 0 66px;
    border-radius: var(--r-lg); background: var(--white); box-shadow: inset 0 0 0 1px var(--line-2), var(--shadow-1);
    transition: box-shadow .45s var(--ease);
}
.fq-search:focus-within { box-shadow: inset 0 0 0 2px var(--ink), 0 0 0 6px var(--signal-soft), var(--shadow-1); }
.fq-search__icon {
    position: absolute; left: 24px; top: 50%; width: 24px; height: 24px; transform: translateY(-50%);
    fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; color: var(--ink-3);
    transition: color .3s, transform .6s var(--ease);
}
.fq-search:focus-within .fq-search__icon { color: var(--signal); transform: translateY(-50%) rotate(-12deg) scale(1.08); }
.fq-search__input {
    flex: 1; min-width: 0; height: 100%; border: 0; outline: none; background: transparent; padding: 0;
    font-size: clamp(17px, 1.45vw, 21px); font-weight: 550; letter-spacing: -0.02em; color: var(--ink);
}
.fq-search__input::placeholder { color: var(--muted); font-weight: 450; }
.fq-search__input::-webkit-search-cancel-button, .fq-search__input::-webkit-search-decoration { -webkit-appearance: none; appearance: none; display: none; }
.fq-search__clear { position: relative; flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--paper-2); transition: background .3s, transform .5s var(--ease); }
.fq-search__clear i::before, .fq-search__clear i::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 1.5px; background: var(--ink); transform: translate(-50%, -50%) rotate(45deg); }
.fq-search__clear i::after { transform: translate(-50%, -50%) rotate(-45deg); }
.fq-search__clear:hover { background: var(--paper-3); transform: rotate(90deg); }
.fq-search__kbd {
    flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px;
    box-shadow: inset 0 0 0 1px var(--line-2), 0 2px 0 var(--line);
    font-family: var(--font-mono); font-size: 13px; color: var(--muted); transition: opacity .3s;
}
.fq-search:focus-within .fq-search__kbd { opacity: 0; }

/* ---------- 2. 분류 칩 / 개수 ---------- */
.fq-bar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px 28px; margin: 22px 0 clamp(44px, 5vw, 72px); }
.fq-chips { flex: 1 1 auto; min-width: 0; }
.fq-chips .c-chip.is-zero { opacity: .42; }
.fq-count { flex: none; font-family: var(--font-sans); font-size: 14px; letter-spacing: -0.01em; }
.fq-count strong { font-family: var(--font-mono); margin-right: 1px; }

/* ---------- 3. 그룹 / 아코디언 ---------- */
.fq-group + .fq-group { margin-top: clamp(60px, 6.5vw, 96px); }
.fq-group__head { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: baseline; gap: 6px 18px; padding-bottom: 20px; }
.fq-group__head::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: var(--ink); transform-origin: 0 50%; transition: transform 1.3s var(--ease) .15s; }
html.js .fq-group__head[data-reveal]:not(.is-in)::after { transform: scaleX(0); }
.fq-group__num { font-family: var(--font-mono); font-size: 14px; font-weight: 600; color: var(--signal); }
.fq-group__title { font-size: clamp(24px, 2.2vw, 32px); font-weight: 700; line-height: 1.3; letter-spacing: -0.035em; }
.fq-group__count { font-size: 13.5px; color: var(--muted); }
.fq-group__count span { font-family: var(--font-mono); font-weight: 600; color: var(--ink-2); margin-right: 1px; }
.fq-group__desc { grid-column: 1 / -1; font-size: 15px; color: var(--muted); }
.fq-acc { border-top: 0; }

.fq-item { position: relative; isolation: isolate; scroll-margin-top: calc(var(--header-h) + var(--subnav-h) + 28px); transition: background-color .5s var(--ease); }
.fq-item::before {
    content: ""; position: absolute; left: 0; top: -1px; bottom: -1px; width: 3px; z-index: 1;
    background: var(--signal); transform: scaleY(0); transform-origin: 50% 0; transition: transform .7s var(--ease);
}
/* 호버: 아래에서 차오르는 옅은 면 */
.fq-item::after { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--white); transform: scaleY(0); transform-origin: 50% 100%; transition: transform .55s var(--ease); }
.fq-item:hover::after, .fq-item[open]::after { transform: scaleY(1); }
.fq-item[open]::before { transform: scaleY(1); }
.fq-item.is-target::after { animation: fq-target 2.4s var(--ease); }
@keyframes fq-target { 0%, 35% { background-color: var(--signal-soft); } 100% { background-color: var(--white); } }

.fq-q { gap: 18px; padding: 26px 18px 26px 22px; }
.fq-q:focus-visible { outline-offset: -2px; }
.fq-mark-q, .fq-mark-a { width: 34px; display: flex; flex-direction: column; align-items: flex-start; gap: 3px; padding-top: .08em; }
.fq-mark-q b, .fq-mark-a b { font-size: 18px; line-height: 1.25; font-weight: 600; }
.fq-mark-q b { transition: transform .5s var(--ease-back); }
.fq-item:hover .fq-mark-q b { transform: translateX(3px); }
.fq-mark-q small { font-size: 10.5px; font-weight: 500; letter-spacing: .06em; color: var(--muted); }
.fq-mark-a b { color: var(--ink); }
.fq-q .c-acc__icon { margin-top: -2px; }
.fq-q .c-acc__text { text-wrap: balance; }
.fq-item:hover .c-acc__icon { box-shadow: inset 0 0 0 1px var(--signal); }

.fq-a { gap: 18px; padding: 0 64px 32px 22px; }
.fq-item[open] .fq-a { animation: fq-ans .75s var(--ease) both; }
@keyframes fq-ans { from { opacity: 0; transform: translate3d(0, 12px, 0); } to { opacity: 1; transform: none; } }
.fq-a__body { flex: 1; min-width: 0; }
.fq-answer { font-size: 16.5px; line-height: 1.85; color: var(--ink-3); }
/* 레거시 에디터 인라인 스타일(글꼴·크기·색) 무력화 */
.fq-answer * { font-family: inherit !important; font-size: inherit !important; line-height: inherit !important; color: inherit !important; background-color: transparent !important; }
.fq-answer p { margin: 0; }
.fq-answer p + p, .fq-answer ul, .fq-answer ol, .fq-answer table { margin-top: .8em; }
.fq-answer ul { list-style: disc; padding-left: 1.3em; }
.fq-answer ol { list-style: decimal; padding-left: 1.3em; }
.fq-answer li::marker { color: var(--signal); }
.fq-answer strong, .fq-answer b { color: var(--ink) !important; font-weight: 700; }
.fq-answer a { color: var(--signal) !important; text-decoration: underline; text-underline-offset: 3px; }
.fq-answer img { max-width: 100% !important; height: auto !important; border-radius: 10px; }
.fq-answer table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; font-size: 15px !important; }
.fq-answer th, .fq-answer td { border: 1px solid var(--line-2); padding: 8px 12px; text-align: left; }
.fq-answer p:empty { display: none; }
/* 가운뎃점으로 이어진 낱말 묶음(서버에서 감쌈)은 점에서 줄바꿈하지 않는다 */
.fq-nb { white-space: nowrap; }

.fq-a__foot { display: flex; align-items: center; justify-content: flex-start; flex-wrap: wrap; gap: 10px 16px; margin-top: 22px; padding-top: 16px; border-top: 1px dashed var(--line-2); }
.fq-copy {
    display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px; border-radius: var(--r-pill);
    font-size: 13px; font-weight: 600; color: var(--ink-3); box-shadow: inset 0 0 0 1px var(--line-2);
    transition: background .35s var(--ease), color .35s var(--ease), box-shadow .35s;
}
.fq-copy svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.fq-copy:hover { color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.fq-copy.is-done { background: var(--ink); color: #fff; box-shadow: inset 0 0 0 1px var(--ink); }

.fq-hit {
    display: inline-flex; align-items: center; gap: 6px; margin-left: 10px; height: 22px; padding: 0 8px; border-radius: 4px; vertical-align: 2px;
    background: var(--signal-soft); color: var(--ink-2); font-size: 11.5px; line-height: 22px; font-weight: 600; letter-spacing: -0.01em;
}
.fq-hit::before { content: ""; width: 5px; height: 5px; border-radius: 1px; background: var(--signal); }
/* 검색어 하이라이트: 형광펜(테이프 옐로우 면 + 잉크 글자) */
mark.fq-hl { background: linear-gradient(transparent 55%, var(--tape) 0); color: inherit; padding: 0 1px; border-radius: 1px; }

/* 답변 · 질문의 화살표 등 장식 기호 대체 (출력 시 fqGlyph 가 삽입) */
.fq-glyph { display: inline-block; width: .95em; height: .95em; margin: 0 .14em; vertical-align: -.12em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fq-dot { display: inline-block; width: .38em; height: .38em; margin: 0 .3em .12em 0; border-radius: 1px; background: var(--signal); vertical-align: middle; }

.fq-empty { margin-top: 8px; }
.fq-empty__icon { width: 44px; height: 44px; fill: none; stroke: var(--signal); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.fq-empty p { font-size: 15px; }
.fq-empty__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 10px; }

/* ---------- 4. 사이드 문의 패널 (다크: data-theme="dark") ---------- */
.fq-side { align-self: stretch; min-width: 0; }
.fq-side__sticky {
    position: sticky; top: calc(var(--header-h) + var(--subnav-h) + 32px);
    display: flex; flex-direction: column; gap: 16px; transition: top .6s var(--ease);
}
body.is-header-hidden .fq-side__sticky { top: calc(var(--subnav-h) + 32px); }
.fq-help {
    position: relative; isolation: isolate; overflow: hidden;
    display: flex; flex-direction: column; gap: 18px; padding: 34px 30px 26px;
    border-radius: var(--r-lg); background: var(--night); color: #fff;
}
.fq-help__grid {
    position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background-image: linear-gradient(var(--night-line) 1px, transparent 1px), linear-gradient(90deg, var(--night-line) 1px, transparent 1px);
    background-size: 32px 32px; background-position: -1px -1px;
    -webkit-mask-image: linear-gradient(200deg, #000 5%, transparent 60%); mask-image: linear-gradient(200deg, #000 5%, transparent 60%);
}
.fq-help__icon { position: absolute; right: 26px; top: 28px; width: 56px; height: 56px; fill: none; stroke: var(--signal); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.fq-help__main, .fq-help__contact { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.fq-help__title { font-size: clamp(24px, 2vw, 30px); font-weight: 720; line-height: 1.25; letter-spacing: -0.04em; }
.fq-help__desc { font-size: 15px; line-height: 1.7; color: var(--fog); }
.fq-help .c-btn { margin-top: 4px; }
.fq-help__tel { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; padding-top: 18px; border-top: 1px solid var(--night-line); }
.fq-help__tel-label { font-size: 13px; color: var(--fog-2); }
.fq-help__tel strong { font-size: clamp(26px, 2.2vw, 32px); font-weight: 700; letter-spacing: -0.03em; transition: color .3s; }
.fq-help__tel:hover strong { color: var(--signal); }
.fq-help__ext > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 11px 0; border-top: 1px solid var(--night-line); font-size: 14px; }
.fq-help__ext dt { color: var(--fog-2); }
.fq-help__ext dd { color: #fff; text-align: right; }
.fq-help__ext dd .c-mono { font-size: 13.5px; margin-left: 2px; }
.fq-help__ext a { transition: color .3s; }
.fq-help__ext a:hover { color: var(--signal); }

.fq-stat { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.fq-stat > div { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 8px; padding: 18px 20px; border-radius: var(--r); background: var(--white); box-shadow: inset 0 0 0 1px var(--line); }
.fq-stat > div::after { content: ""; position: absolute; left: 0; top: 0; height: 2px; width: 100%; background: var(--signal); transform-origin: 0 50%; transition: transform 1.3s var(--ease) .3s; }
html.js .fq-stat[data-reveal]:not(.is-in) > div::after { transform: scaleX(0); }
.fq-stat__num { font-size: 40px; font-weight: 720; line-height: 1; letter-spacing: -0.05em; font-variant-numeric: tabular-nums; }
.fq-stat__label { font-size: 13px; color: var(--muted); }

/* ---------- 5. 데이터 복구와 디지털 포렌식 비교 (다크, 스크롤 확장) ---------- */
.fq-vs { overflow: hidden; isolation: isolate; }
.fq-vs__bg {
    position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .7;
    background-image: linear-gradient(var(--night-line) 1px, transparent 1px), linear-gradient(90deg, var(--night-line) 1px, transparent 1px);
    background-size: 88px 88px; background-position: -1px -1px;
    -webkit-mask-image: radial-gradient(ellipse 60% 70% at 85% 15%, #000 10%, transparent 70%); mask-image: radial-gradient(ellipse 60% 70% at 85% 15%, #000 10%, transparent 70%);
}
.fq-vs__wrap { --pl: 60%; position: relative; isolation: isolate; }
/* B(디지털 포렌식) 열 하이라이트 패널 : 데스크톱에선 스크롤에 따라 위에서 아래로 칠해진다 */
.fq-vs__panel {
    position: absolute; z-index: -1; left: var(--pl); right: 0; top: 0; bottom: 0; pointer-events: none;
    border-radius: 18px; background: rgba(var(--signal-rgb), .07);
    box-shadow: inset 0 2px 0 var(--signal), inset 0 0 0 1px rgba(var(--signal-rgb), .16);
    transform-origin: 50% 0;
}
.fq-vs__table { width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; }
.fq-vs__table th, .fq-vs__table td {
    position: relative; text-align: left; vertical-align: middle;
    padding: clamp(20px, 2.2vw, 30px) clamp(16px, 2.2vw, 36px); border-bottom: 1px solid var(--night-line);
}
.fq-vs__table thead th {
    padding-top: clamp(22px, 2.4vw, 32px); padding-bottom: 26px; border-bottom: 1.5px solid var(--night-line-2);
    font-size: clamp(20px, 2vw, 30px); font-weight: 700; letter-spacing: -0.035em; line-height: 1.25; color: var(--fog);
}
.fq-vs__table thead th .c-mono { display: block; margin-bottom: 10px; font-size: 11px; font-weight: 500; letter-spacing: .14em; color: var(--fog-2); }
.fq-vs__table thead th.fq-vs__k { width: 20%; vertical-align: bottom; font-size: 13px; font-weight: 600; letter-spacing: 0; color: var(--fog-2); }
.fq-vs__table thead th.fq-vs__b { padding-left: calc(clamp(16px, 2.2vw, 36px) + 22px); color: #fff; }
.fq-vs__table tbody th.fq-vs__k { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; color: var(--fog-2); }
.fq-vs__table tbody th.fq-vs__k::before { content: ""; display: inline-block; width: 14px; height: 1px; margin-right: 10px; vertical-align: .3em; background: var(--night-line-2); }
.fq-vs__table td.fq-vs__a { font-size: clamp(16px, 1.4vw, 20px); color: var(--fog-2); }
.fq-vs__table td.fq-vs__b { font-size: clamp(17px, 1.5vw, 22px); font-weight: 650; color: #fff; }
.fq-vs__table td.fq-vs__b, .fq-vs__table thead th.fq-vs__b { padding-left: calc(clamp(16px, 2.2vw, 36px) + 22px); }
.fq-vs__table tbody tr:last-child th, .fq-vs__table tbody tr:last-child td { border-bottom: 0; }
.fq-vs__v { display: inline-flex; align-items: center; gap: 14px; }
.fq-vs__check { flex: none; width: 22px; height: 22px; fill: none; stroke: var(--signal); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.fq-vs__table tbody tr { transition: background .4s var(--ease); }
.fq-vs__table tbody tr:hover { background: rgba(255, 255, 255, .03); }
.fq-vs__badge {
    position: absolute; left: 0; top: 50%; transform: translate(-50%, -50%);
    display: grid; place-items: center; width: 58px; height: 58px; border-radius: 50%;
    background: var(--signal); color: var(--on-signal); box-shadow: 0 0 0 8px var(--night);
    font-family: var(--font-sans); font-style: normal; font-size: 25px; font-weight: 400; letter-spacing: -0.02em;
}
html.js .fq-vs__wrap[data-reveal] .fq-vs__badge { transform: translate(-50%, -50%) scale(.4) rotate(-30deg); opacity: 0; transition: transform 1.1s var(--ease-back) .5s, opacity .5s ease .5s; }
html.js .fq-vs__wrap[data-reveal].is-in .fq-vs__badge { transform: translate(-50%, -50%); opacity: 1; }

/* ---------- 6. 반응형 ---------- */
@media (max-width: 1024px) {
    .fq-layout { grid-template-columns: 1fr; }
    .fq-side { margin-top: 16px; }
    .fq-side__sticky { position: static; }
    /* 태블릿: 문의 카드를 넓은 2단 밴드로 (안내 + 버튼 | 전화 + 내선) */
    .fq-help { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; gap: 24px clamp(32px, 5vw, 56px); padding: 36px 34px 30px; }
    .fq-help__contact { gap: 12px; }
    .fq-help__tel { margin-top: 0; padding-top: 0; border-top: 0; }
}
@media (max-width: 760px) {
    .fq-kinetic span { font-size: clamp(64px, 22vw, 96px); -webkit-text-stroke-width: 1px; }
    .fq-search { height: 60px; padding: 0 12px 0 50px; border-radius: var(--r); }
    .fq-search__icon { left: 17px; width: 21px; height: 21px; }
    .fq-search__input { font-size: 16px; }
    .fq-search__kbd { display: none; }
    .fq-bar { flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 14px; margin-top: 18px; }
    .fq-chips { flex: none; }
    .fq-group__head { grid-template-columns: auto minmax(0, 1fr); padding-bottom: 16px; }
    .fq-group__count { grid-column: 1 / -1; }
    .fq-q { gap: 12px; padding: 22px 4px 22px 14px; font-size: 16.5px; }
    .fq-a { gap: 12px; padding: 0 8px 26px 14px; }
    .fq-mark-q, .fq-mark-a { width: 26px; }
    .fq-mark-q b, .fq-mark-a b { font-size: 16px; }
    .fq-q .c-acc__icon { width: 28px; height: 28px; }
    .fq-answer { font-size: 15.5px; }
    .fq-hit { margin-left: 6px; }
    .fq-help { display: flex; align-items: stretch; padding: 28px 22px 22px; }
    .fq-help__icon { width: 44px; height: 44px; right: 20px; top: 22px; }
    .fq-help__tel { margin-top: 6px; padding-top: 18px; border-top: 1px solid var(--night-line); }
    .fq-copy { height: 40px; padding: 0 16px; }
    /* 칩 레일은 가로 스크롤: 오른쪽 끝을 흐리게 해 더 있음을 알린다 */
    .fq-chips { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - var(--gutter)), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - var(--gutter)), transparent); }

    /* 비교표: A / B 두 열, 행 제목은 각 쌍 위의 작은 캡션 */
    .fq-vs__wrap { --pl: 44%; }
    .fq-vs__table, .fq-vs__table thead, .fq-vs__table tbody { display: block; }
    .fq-vs__table tr { display: grid; grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr); }
    .fq-vs__table thead th.fq-vs__k { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); border: 0; }
    .fq-vs__table thead th { font-size: 17px; padding: 18px 14px 16px; }
    .fq-vs__table thead th .c-mono { margin-bottom: 6px; }
    .fq-vs__table thead th.fq-vs__b { padding-left: 32px; }
    .fq-vs__table tbody th.fq-vs__k {
        grid-column: 1 / -1; padding: 18px 14px 0; border-bottom: 0;
        font-size: 12.5px; font-weight: 600; color: var(--fog-2);
    }
    .fq-vs__table tbody th.fq-vs__k::before { width: 10px; margin-right: 8px; }
    .fq-vs__table tbody td { padding: 8px 14px 18px; line-height: 1.5; text-wrap: balance; }
    .fq-vs__table td.fq-vs__a { font-size: 14.5px; }
    .fq-vs__table td.fq-vs__b { font-size: 15px; padding-left: 14px; }
    .fq-vs__v { align-items: flex-start; gap: 8px; }
    .fq-vs__check { width: 17px; height: 17px; margin-top: 3px; }
    .fq-vs__panel { border-radius: 14px; }
    .fq-vs__table tbody tr:last-child td.fq-vs__a { border-bottom: 0; }
    .fq-vs__badge { width: 38px; height: 38px; font-size: 17px; box-shadow: 0 0 0 5px var(--night); }
}
@media (prefers-reduced-motion: reduce) {
    .fq-vs__badge { opacity: 1 !important; transform: translate(-50%, -50%) !important; }
}
