/* ============================================================
   ARIFE 정리 v2600 — 넘치는 단추 · 겹치는 칸 · 스크롤 막대

   글자 크기는 이 파일이 아니라 각 CSS 원본을 직접 고쳤다.
   11px 을 바닥으로 올렸다(장식용 초소형 표시만 10px).
   덮어쓰기 층을 또 쌓지 않으려고 일부러 원본을 고쳤다.
   ============================================================ */

/* ── 1) 마켓 '미리보기' 단추 ────────────────────────────────
   두 벌의 디자인이 겹쳐 있었다.
     v225      — 지름 50px 동그라미, 글자 숨김(font-size:0)
     v1800     — 아래쪽 알약, 글자 9px
   v1800 이 나중이라 글자 크기·모양은 이겼는데 폭·높이(50px)는
   v225 것이 남았다. 그래서 50px 상자 안에 '미리보기' 네 글자가
   한 줄에 한 글자씩 쌓이고 상자 밖으로 흘러넘쳤다.

   동그라미 하나로 정한다. ▶ 하나로 뜻이 통하고, 옆의 '미리보기'
   글자는 없어도 되는 군더더기였다. 읽어 주는 기계에는
   aria-label 로 그대로 남는다. */
.market-preview-trigger:not(#_):not(#_){
  position:absolute!important;
  z-index:9!important;
  left:50%!important;
  top:50%!important;
  right:auto!important;
  bottom:auto!important;
  width:52px!important;
  min-width:52px!important;
  max-width:52px!important;
  height:52px!important;
  min-height:52px!important;
  max-height:52px!important;
  display:grid!important;
  place-items:center!important;
  gap:0!important;
  padding:0!important;
  overflow:hidden!important;
  border:1px solid rgba(220,236,247,.46)!important;
  border-radius:50%!important;
  background:linear-gradient(145deg,rgba(45,68,85,.94),rgba(9,17,23,.94))!important;
  box-shadow:inset 0 1px rgba(255,255,255,.16),0 8px 24px rgba(0,0,0,.4)!important;
  color:#f7fbff!important;
  font-size:0!important;      /* 옆 글자를 지운다 */
  line-height:1!important;
  transform:translate(-50%,-50%)!important;
  opacity:1!important;
}
/* v226 이 단추 안을 `<span>▶</span><b>미리보기</b>` 로 다시 그린다 —
   글자 쪽은 확실히 접어 둔다. */
.market-preview-trigger:not(#_):not(#_) > b{
  display:none!important;
}
.market-preview-trigger:not(#_):not(#_) > span{
  display:block!important;
  margin-left:2px!important;   /* ▶ 는 왼쪽이 비어 보인다 */
  font-size:17px!important;
  line-height:1!important;
}
.market-preview-trigger:not(#_):not(#_):hover{
  border-color:#8fd8ee!important;
  box-shadow:inset 0 1px rgba(255,255,255,.2),0 10px 28px rgba(0,0,0,.46),0 0 22px rgba(112,221,245,.24)!important;
}

/* ── 2) 기업 라이선스 미리보기 도장 ─────────────────────────
   'BUSINESS PREVIEW' 글자가 도장 상자를 38px 넘어 나갔다.
   ARIFE 로고가 이미 '미리보기 워터마크'라는 뜻을 전한다 —
   옆 글자는 지우고 로고만 남긴다. */
.enterprise-preview__watermark:not(#_):not(#_){
  width:auto!important;
  max-width:calc(100% - 34px)!important;
  height:auto!important;
  flex-wrap:nowrap!important;
  overflow:hidden!important;
}
.enterprise-preview__watermark:not(#_):not(#_) > span{
  display:none!important;
}

/* ── 3) AI 스튜디오 '고급 설정' 이 닫혀도 열려 있던 것 ───────
   `<details>` 가 닫히면 브라우저가 안쪽을 감춘다. 그런데 10차 묶음이
   `.unified-advanced label{display:block!important}` 을 걸어 두어
   그 규칙을 깨 버렸다. 그래서 접어 둔 '제외할 요소' 입력칸이
   아래 '생성 준비 상태' 칸 위에 얹혀 있었다.
   닫혀 있으면 확실히 감춘다. */
details:not([open]):not(#_):not(#_) > :not(summary){
  display:none!important;
}

/* ── 4) 스크롤 막대가 칸 밖으로 보이던 것 ───────────────────
   둥근 모서리 칸 안에서 막대가 모서리 밖 네모 자리에 그려져
   테두리를 뚫고 나온 것처럼 보였다. 얇고 안쪽에 붙는 막대로 바꾼다.
   모든 스크롤 칸에 같은 모양이라 화면마다 달라 보이지도 않는다. */
:where(html) *{
  scrollbar-width:thin;
  scrollbar-color:rgba(126,164,205,.42) transparent;
}
::-webkit-scrollbar{ width:8px; height:8px; }
::-webkit-scrollbar-track{ background:transparent; }
::-webkit-scrollbar-thumb{
  border:2px solid transparent;
  border-radius:99px;
  background:rgba(126,164,205,.42);
  background-clip:padding-box;
}
::-webkit-scrollbar-thumb:hover{ background:rgba(150,192,232,.6); background-clip:padding-box; }
::-webkit-scrollbar-corner{ background:transparent; }

/* 둥근 칸은 안쪽 내용을 모서리에 맞춰 자른다 — 막대가 모서리를 뚫지 않는다 */
:is([class*="-panel"],[class*="-card"],[class*="-shell"],[class*="-inspector"],[class*="-library"],[class*="-feed"]):not(#_):not(#_){
  overflow-clip-margin:0;
}

/* ============================================================
   v2610 — 밝은 화면 위의 '검은 창' 구조대 (2026-08-23 사장님 지시)

   arife-unified-v400.css 가 어두운 시절 규칙으로 도구 대화창 전부를
   남색 판(#152033→#080e18)으로 칠한다. 화면은 이미 다 밝아졌는데
   세부로 들어갈 때 뜨는 창(모델 고르기·보관함 고르기·버전 고르기·
   프로젝트 관리·결과 검토·다리 연결)만 검게 남아 있었다 — "가끔
   팝업이 검다"의 정체. 로그인·요금 창과 같은 밝은 유리로 맞춘다.
   (이미지 창은 droplet-v910, 진행 창은 glass-console-v600 이 이미
   밝게 칠해 두었다 — 여기서는 빠진 것만 맡는다.)
   ============================================================ */
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-backdrop,.motion-library-backdrop,.motion-model-backdrop,
  .stock-video-backdrop,.film-modal-backdrop,.film-bridge-backdrop,
  .studio-version-backdrop,.project-manager-backdrop-v311,.generation-modal-backdrop-v315
){
  background:rgba(16,32,54,.5)!important;
  backdrop-filter:blur(10px) saturate(1.05)!important;
  -webkit-backdrop-filter:blur(10px) saturate(1.05)!important;
}
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-card,.motion-library-dialog,.motion-model-dialog,
  .stock-video-dialog,.film-modal-card,.film-bridge-dialog,
  .studio-version-dialog,.project-manager-dialog-v311,.generation-review-dialog-v315
){
  border:1px solid rgba(160,196,244,.65)!important;
  background:
    radial-gradient(96% 60% at 50% 0%,#fff,rgba(244,248,254,.94) 44%,rgba(228,238,250,.92))!important;
  background-color:#eef4fc!important;
  box-shadow:inset 0 1.5px 1px -1px #fff,0 30px 70px -30px rgba(20,45,90,.55)!important;
  color:#16324f!important;
}
/* 머리·발판 */
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-card,.motion-library-dialog,.motion-model-dialog,
  .stock-video-dialog,.film-modal-card,.film-bridge-dialog,
  .studio-version-dialog,.project-manager-dialog-v311,.generation-review-dialog-v315
) > :is(header,footer){
  border-color:rgba(160,196,244,.45)!important;
  background:rgba(255,255,255,.6)!important;
}
/* 글자 — 밝은 판 위에서 읽히게 */
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-card,.motion-library-dialog,.motion-model-dialog,
  .stock-video-dialog,.film-modal-card,.film-bridge-dialog,
  .studio-version-dialog,.project-manager-dialog-v311,.generation-review-dialog-v315
) :is(h1,h2,h3,strong,b,dt,legend){ color:#14202e!important }
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-card,.motion-library-dialog,.motion-model-dialog,
  .stock-video-dialog,.film-modal-card,.film-bridge-dialog,
  .studio-version-dialog,.project-manager-dialog-v311,.generation-review-dialog-v315
) :is(p,small,span,em,li,td,dd,i){ color:#4a5870!important }
/* 형광 코드가 쓰던 강조 글자는 파랑으로 */
html body:not(#nope):not(#_):not(#__) :is(
  .studio-version-dialog header small,.studio-version-dialog footer span,
  .motion-model-dialog>header small,.studio-version-top em,
  .motion-model-option-copy>small
){ color:#2f6ec9!important;background:none!important }
/* 고르는 칸(버전·모델·목록) — 흰 물방울, 고른 것은 파란 테 */
html body:not(#nope):not(#_):not(#__) :is(
  .studio-version-option,.motion-model-option,
  .project-manager-dialog-v311 :is(article,li[class]),
  .motion-library-dialog :is(article,.motion-library-item)
){
  border:1px solid rgba(140,170,215,.5)!important;
  background:rgba(255,255,255,.72)!important;
  box-shadow:0 8px 16px -12px rgba(20,45,90,.4)!important;
  color:#16324f!important;
}
html body:not(#nope):not(#_):not(#__) :is(.studio-version-option,.motion-model-option):hover{
  border-color:rgba(47,110,201,.65)!important;
}
html body:not(#nope):not(#_):not(#__) :is(.studio-version-option.active,.motion-model-option.active){
  border-color:rgba(47,110,201,.85)!important;
  background:linear-gradient(180deg,rgba(219,233,252,.95),rgba(206,224,248,.9))!important;
  box-shadow:0 0 0 3px rgba(91,155,236,.25)!important;
}
/* 알약·꼬리표 */
html body:not(#nope):not(#_):not(#__) :is(
  .studio-version-specs b,.motion-model-option-copy i
){
  border:1px solid rgba(140,170,215,.5)!important;
  background:rgba(255,255,255,.8)!important;
  color:#3c527a!important;
}
/* 닫기 단추 — 흰 물방울 */
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-close,.motion-library-close,.motion-model-close,.stock-video-close,
  .film-modal-close,.film-bridge-close,.studio-version-dialog header>button,
  .project-manager-dialog-v311>header>button,.generation-review-dialog-v315>header>button
){
  border:1px solid rgba(150,180,225,.6)!important;
  background:linear-gradient(180deg,#fff,rgba(233,240,250,.9))!important;
  box-shadow:0 6px 12px -8px rgba(20,45,90,.5)!important;
  color:#22334a!important;
}
/* 창 속 일반 단추 — 흰 물방울, 주(파랑) 단추만 파랗게 */
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-card,.motion-library-dialog,.motion-model-dialog,
  .stock-video-dialog,.film-modal-card,.film-bridge-dialog,
  .studio-version-dialog,.project-manager-dialog-v311,.generation-review-dialog-v315
) :is(footer button,footer a){
  border:1px solid rgba(150,180,225,.55)!important;
  background:linear-gradient(180deg,#fff,rgba(233,240,250,.9))!important;
  color:#22334a!important;
  box-shadow:0 6px 12px -8px rgba(20,45,90,.45)!important;
}
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-card,.motion-library-dialog,.motion-model-dialog,
  .stock-video-dialog,.film-modal-card,.film-bridge-dialog,
  .studio-version-dialog,.project-manager-dialog-v311,.generation-review-dialog-v315
) :is(footer button.primary,footer a.primary,footer [data-primary],.is-main){
  border-color:transparent!important;
  background:
    radial-gradient(92% 58% at 50% 4%,rgba(255,255,255,.85),rgba(234,241,250,.38) 36%,rgba(255,255,255,0) 60%),
    linear-gradient(180deg,rgba(112,168,244,.95),rgba(28,86,190,.97) 82%,rgba(64,124,214,.97))!important;
  color:#fff!important;
}
/* 창 속 입력 칸 */
html body:not(#nope):not(#_):not(#__) :is(
  .motion-modal-card,.motion-library-dialog,.motion-model-dialog,
  .stock-video-dialog,.film-modal-card,.film-bridge-dialog,
  .studio-version-dialog,.project-manager-dialog-v311,.generation-review-dialog-v315
) :is(input,select,textarea):not([type=checkbox]):not([type=radio]){
  border:0!important;
  background:rgba(255,255,255,.9)!important;
  box-shadow:inset 0 0 0 1px rgba(150,180,225,.55)!important;
  color:#16324f!important;
}
