/* ============================================================
   ARIFE 조건 내리는 패널 v100 — 물방울 옷

   `:not(#a)…:not(#e)` 는 아이디 다섯 개 무게 — 이 시트가 맨 뒤에
   실리므로 어느 옷과 겨뤄도 이긴다. 패널 안으로 옮겨 온 딱지들은
   원래 옷(가로 알약)을 벗기고 세로 목록 줄로 다시 입힌다.
   ============================================================ */

/* ── 단추 ── */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-drop{
  position:relative;display:inline-block;flex:0 0 auto;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-btn{
  display:inline-flex;align-items:center;gap:9px;
  min-height:46px;padding:0 16px;
  border:0;border-radius:15px;cursor:pointer;
  background:radial-gradient(96% 60% at 50% 2%,#fff,rgba(255,255,255,.9) 44%,rgba(246,250,255,.84));
  box-shadow:
    inset 0 1.5px 1px -1px #fff,
    inset 0 0 0 1px rgba(160,196,244,.6),
    0 12px 22px -14px rgba(20,45,90,.5);
  font:inherit;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-btn:hover{
  box-shadow:
    inset 0 1.5px 1px -1px #fff,
    inset 0 0 0 1px rgba(140,185,245,.95),
    0 16px 26px -14px rgba(20,45,90,.55);
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-btn small{
  color:#63799a;font-size:10.5px;font-weight:800;letter-spacing:.05em;white-space:nowrap;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-btn b{
  max-width:170px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
  color:#16324f;font-size:13.5px;font-weight:800;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-btn i{
  color:#3f74c8;font-style:normal;font-size:11px;transition:transform .16s ease;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-drop.is-open .afd-btn i{transform:rotate(180deg)}

/* ── 펼쳐지는 판 ── */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel{
  position:absolute;left:0;top:calc(100% + 9px);z-index:120;
  min-width:max(100%,216px);max-height:340px;overflow:auto;
  padding:8px;border-radius:17px;
  background:linear-gradient(165deg,#ffffff,#f2f7fd);
  box-shadow:
    inset 0 1.5px 1px -1px #fff,
    inset 0 0 0 1px rgba(160,196,244,.5),
    0 30px 56px -22px rgba(18,45,88,.45);
  opacity:0;visibility:hidden;transform:translateY(-6px);
  transition:opacity .16s ease,transform .16s ease,visibility .16s;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-drop.is-open .afd-panel{
  opacity:1;visibility:visible;transform:none;
}

/* 판 안의 딱지 상자 — 세로 목록으로 다시 편다 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel .market-tags,
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel .mk-con-chips-v3700,
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel .enterprise-tags{
  display:flex!important;flex-direction:column!important;gap:3px!important;
  margin:0!important;padding:0!important;border:0!important;
  background:none!important;box-shadow:none!important;max-width:none!important;
}

/* 판 안의 줄(딱지·정렬 항목) 공통 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel button{
  display:flex!important;align-items:center!important;justify-content:flex-start!important;
  gap:10px!important;width:100%!important;min-height:41px!important;
  margin:0!important;padding:0 13px!important;
  border:0!important;border-radius:12px!important;
  background:transparent!important;box-shadow:none!important;
  color:#2c4a70!important;font-size:13px!important;font-weight:700!important;
  text-align:left!important;cursor:pointer;white-space:nowrap;
  transform:none!important;filter:none!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel button *{
  color:inherit!important;font-size:inherit!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel button:hover{
  background:rgba(91,155,236,.12)!important;color:#123c6e!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel button.is-on,
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel button.active,
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel button[aria-pressed="true"]{
  background:linear-gradient(180deg,#5b9bec,#2f6ec9)!important;
  box-shadow:inset 0 1.5px 1px -1px rgba(255,255,255,.8),0 10px 18px -12px rgba(30,80,160,.8)!important;
  color:#fff!important;
}

/* 화면비 딱지의 작은 모양 상자는 살린다 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel button u{
  flex:0 0 auto;width:24px;min-height:10px;
  border:1.6px solid currentColor;border-radius:4px;opacity:.75;
  background:none!important;display:inline-block;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel button u.mk-ar-all-v3700{
  border-style:dashed;aspect-ratio:4/3;
}

/* 용도 딱지의 코드 글자(AD·ART…)는 판에서 뺀다 — 줄이 길어진다 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel .market-tag i{display:none!important}

/* ── 조건 줄 배치 ── */
/* 기업 라이선스: [카테고리 ▾][검색(넓게)][정렬 ▾] 한 줄 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-bar{
  display:flex!important;flex-wrap:wrap;align-items:center;gap:10px!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-bar .enterprise-filterbar__tools{
  flex:1 1 340px;display:flex!important;align-items:center;gap:10px!important;margin:0!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-bar .enterprise-filterbar__tools label{
  flex:1 1 auto;margin:0!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-bar input[type="search"]{
  width:100%;min-height:46px;padding:0 18px;
  border:0!important;border-radius:15px!important;
  background:rgba(255,255,255,.82)!important;color:#16324f!important;font-size:13px;
  box-shadow:inset 0 1.5px 1px -1px #fff,inset 0 0 0 1px rgba(160,196,244,.55)!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-bar input[type="search"]:focus{
  outline:none;box-shadow:inset 0 1.5px 1px -1px #fff,inset 0 0 0 1px rgba(120,170,240,.95)!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-bar input[type="search"]::placeholder{color:#7d95b3}

/* 마켓 조건 콘솔: 묶음 상자 겉옷을 벗기고 단추만 한 줄로 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-row-v3700{
  display:flex!important;flex-wrap:wrap;align-items:center;gap:10px!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-group-v3700.afd-group{
  display:block!important;flex:0 0 auto!important;width:auto!important;min-width:0!important;
  margin:0!important;padding:0!important;border:0!important;
  background:none!important;box-shadow:none!important;
}

/* ============================================================
   v110 — 펼친 판이 상품 카드 '뒤'로 숨는 문제(마켓 실측)
   조건 콘솔을 카드보다 위층에 올리고, 조상 상자들의 잘라내기를 푼다.
   ============================================================ */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-sheet-wrap-v3700{overflow:visible!important}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-console-v3700{
  position:relative!important;z-index:90!important;overflow:visible!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-con-row-v3700,
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-con-group-v3700,
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-con-slot-v3700{overflow:visible!important}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .enterprise-filterbar{
  position:relative;z-index:90;overflow:visible!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-drop.is-open{z-index:140;position:relative}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel{z-index:220}


/* ============================================================
   v120 — 마켓 조건판 단추 자리
   1줄: 검색이 판 폭을 다 쓴다 · 2줄: 조건 단추들과 조건 지우기
   ============================================================ */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-slot-v3700{
  display:block!important;overflow:visible!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-slot-v3700 input[type="search"],
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console #market-search{
  width:100%!important;min-height:48px;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-row{
  display:flex;flex-wrap:wrap;align-items:center;gap:10px;
  margin-top:12px;overflow:visible!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-row .mk-con-reset-v3700{
  margin-left:auto;min-height:46px;padding:0 18px;
  border:0!important;border-radius:15px!important;cursor:pointer;
  background:radial-gradient(96% 60% at 50% 2%,#fff,rgba(255,255,255,.9) 44%,rgba(246,250,255,.84))!important;
  /* 되돌리는 단추가 화면에서 유일하게 빨갛다. 거르개를 지우는 일은
     되돌릴 수 있는 일인데 「지우면 큰일 난다」로 읽힌다. 옆 알약들과
     같은 결로 두고, 손을 올렸을 때만 붉은 기를 비친다. */
  box-shadow:inset 0 1.5px 1px -1px #fff,inset 0 0 0 1px rgba(160,196,244,.55),0 12px 22px -14px rgba(20,45,90,.45)!important;
  color:#4a5a75!important;font-weight:800!important;font-size:12.5px!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-row .mk-con-reset-v3700:hover{
  background:rgba(255,244,247,.96)!important;color:#95254a!important;
  box-shadow:inset 0 1.5px 1px -1px #fff,inset 0 0 0 1px rgba(216,140,166,.6),0 12px 22px -14px rgba(20,45,90,.45)!important;
}

/* ============================================================
   v130 — 단추 줄이 콘솔 격자의 오른쪽 좁은 칸에 끼어
   세로로 쌓였다(실측). 콘솔을 위→아래 흐름으로 풀어
   검색 줄과 단추 줄이 판 전체 폭을 쓰게 한다.
   ============================================================ */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console{
  display:block!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-head-v3700{
  display:flex;align-items:center;gap:10px;margin:0 0 12px!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-slot-v3700{
  width:100%!important;margin:0 0 2px!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-row{
  width:100%!important;grid-column:1/-1!important;
}
/* 펼친 판이 이웃 단추 뒤로 깔리지 않게 — 묶음 상자의 층 만들기를 없애고
   열린 단추만 위층으로 올린다 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-con-group-v3700.afd-group{
  position:static!important;z-index:auto!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-drop.is-open{z-index:640!important}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel{z-index:650!important}


/* ============================================================
   v140 — 최상층에 띄운 판
   body 바로 아래로 옮겨진 판은 .afd-float 로 표시한다.
   (드롭 상자 밖으로 나가므로 .is-open 연동 규칙이 안 닿는다)
   ============================================================ */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-panel.afd-float{
  opacity:1!important;visibility:visible!important;transform:none!important;
  z-index:2147482000!important;
}

/* ============================================================
   v150 — 조건판 자체가 세로로 커서 상품이 밀려 내려갔다(운영자 실측).
   판을 한 줄로 접는다: [검색(넓게)][용도][화면비][길이][가격][정렬][조건 지우기]
   ============================================================ */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console{
  display:flex!important;flex-wrap:wrap;align-items:center;gap:10px 12px;
  padding:14px 18px!important;
}
/* '조건' 머리글 줄은 접는다 — 자리만 차지한다 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-head-v3700{
  display:none!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-slot-v3700{
  flex:1 1 300px;width:auto!important;margin:0!important;padding:0!important;
  border:0!important;background:none!important;box-shadow:none!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-slot-v3700 input[type="search"],
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console #market-search{
  min-height:46px;margin:0!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .afd-row{
  width:auto!important;flex:0 1 auto;margin:0!important;
}
/* 검색 상자를 감싸던 안쪽 판(tools)이 있으면 겉옷을 벗긴다 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-console .mk-con-slot-v3700 > *{
  margin:0!important;padding:0!important;border:0!important;
  background:none!important;box-shadow:none!important;width:100%;
}

/* ============================================================
   v160 — 조건판이 상품 첫 줄을 덮고 있었다(실측: 판 220~296,
   상품 216~). 감싸는 상자(mk-sheet-wrap)가 격자라 두 아이가
   같은 칸에 겹쳐 얹힌 것 — 위→아래 흐름으로 강제한다.
   ============================================================ */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-sheet-wrap-v3700{
  display:block!important;
}
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-console-v3700{
  margin:0 0 18px!important;
}

/* ── v170: 판이 96px 아래로 밀려 상품을 덮던 진짜 원인 ──
   원래 옷이 붙박이(sticky) 배치용으로 top:96px 를 줬는데,
   우리가 층 문제로 relative 를 강제하면서 그 96px 가
   '항상 아래로 밀기'가 돼 버렸다(실측). 오프셋을 끈다. */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .mk-console-v3700{
  top:0!important;bottom:auto!important;
}

/* ── v180: 기업 라이선스 조건줄도 같은 내려앉음(실측 top:64px) ── */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .enterprise-filterbar{
  top:0!important;bottom:auto!important;margin-bottom:16px!important;
}

/* ══════════════════════════════════════════════════════════
   투명 클릭 도둑 잡기 v190 — 2026-08-29

   「상품을 누르면 사라진다」의 진범이 이 판이었다. 블랙박스 실측:
     10:15:14  계약 팝업 덮개 눌러 닫음
     10:15:15  '빈 자리' 클릭 → 그 클릭이 **접힌 용도 판의 숏폼 칩**에 맞음
     10:15:15  용도가 숏폼으로 바뀌며 다른 상품이 사라짐

   접힌 판은 opacity:0 + visibility:hidden 으로만 숨겨져 있었는데,
   안의 칩(.market-tag)에 visibility 를 되살리는 다른 옷이 입혀져 있어
   **눈에는 안 보이는데 클릭은 받는** 유령이 됐다. 하필 떠 있는 자리
   (942,228 · 216x505, z650)가 상품 카드 첫 줄 오른쪽과 겹쳐서, 두 번째
   상품(고래)을 누르는 클릭이 실제로는 투명 칩을 눌러 용도를 바꿨다 —
   그래서 「다른 상품을 누르면 누른 게 사라지는」 것처럼 보였고, 용도가
   숏폼·시네마틱으로 저절로 바뀌어 있던 것도 전부 이놈이다.

   visibility 는 자식이 되살릴 수 있지만 display:none 은 못 되살린다.
   접힌 판은 display 로 아예 걷는다. (펼침 동작은 is-open 이 맡고, 열린
   판은 body 로 옮겨 뜨므로(afd-float) 이 규칙에 안 걸린다.) */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) .afd-drop:not(.is-open) .afd-panel{
  display:none !important;
  pointer-events:none !important;
}
/* 혹시 판이 body 에 뜬 채로 고아가 되면(닫힘 전환 중) 그것도 못 누르게 */
html body:not(#a):not(#b):not(#c):not(#d):not(#e) body > .afd-panel:not(.afd-float),
body > .afd-panel:not(.afd-float){
  display:none !important;
  pointer-events:none !important;
}
