/* ==========================================================================
   융합디자인 2D 에디토리얼 포트폴리오 스타일시트
   (스위스 모더니즘 / 에디토리얼 그리드 & 흑백 포스터 + 사진 고유 컬러 테마)
   ========================================================================== */

:root {
  /* 공통 폰트 및 트랜지션 */
  --font-display: 'Cinzel', 'Space Grotesk', -apple-system, sans-serif;
  --font-mono: 'Space Grotesk', 'Pretendard', monospace, sans-serif;
  --font-body: 'Pretendard', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  --ease-spring: cubic-bezier(0.18, 0.89, 0.32, 1.28);
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-bounce-back: cubic-bezier(0.34, 1.56, 0.64, 1);

  /* [테마 1: 포스터 흑백 에디토리얼 팔레트] */
  --mono-bg: #f4f3ee;
  --mono-surface: #ffffff;
  --mono-surface-contrast: #000000;
  --mono-border: #141414;
  --mono-border-light: rgba(0, 0, 0, 0.14);
  --mono-text-primary: #0a0a0a;
  --mono-text-secondary: #525252;
  --mono-text-inverse: #f4f3ee;
  --mono-accent: #111111;

  /* [테마 2: 사진 섹션 전용 다크 & 컬러 팔레트] */
  --photo-bg: #0f1217;
  --photo-surface: #171b22;
  --photo-border: rgba(255, 255, 255, 0.12);
  --photo-text-primary: #f8fafc;
  --photo-text-secondary: #94a3b8;
  --photo-accent-blue: #7092b0;
  --photo-accent-cyan: #448fd9;
  --photo-accent-terracotta: #a87d7b;
  --photo-accent-sage: #8e9983;

  /* 그리드 간격 */
  --grid-gap: 24px;
}

/* 기본 리셋 */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-body);
  background-color: var(--mono-bg);
  color: var(--mono-text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
}

/* 포트폴리오 전체 래퍼 */
.portfolio-wrapper {
  max-width: 1720px;
  margin: 0 auto;
  padding: 24px 32px 60px 32px;
  display: flex;
  flex-direction: column;
  gap: 36px;
}

/* ==========================================================================
   1. 에디토리얼 마스트헤드 헤더 (Masthead Header)
   ========================================================================== */
.editorial-masthead {
  border-bottom: 2px solid var(--mono-border);
  padding-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.masthead-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--mono-border-light);
  padding-bottom: 10px;
}

.brand-meta {
  display: flex;
  gap: 20px;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--mono-text-secondary);
}

.meta-tag:not(:last-child)::after {
  content: " /";
  margin-left: 20px;
  color: #a3a3a3;
}

.masthead-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #10b981;
}

.status-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

.masthead-main {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 24px;
}

.title-block {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.main-headline {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5.5vw, 4.4rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 0.95;
  color: var(--mono-text-primary);
  text-transform: uppercase;
}

.sub-headline {
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--mono-text-secondary);
  letter-spacing: -0.01em;
}

/* 카테고리 큐레이션 네비게이션 & 뷰 토글 */
.nav-control-group {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.category-curation-nav {
  display: flex;
  border: 2px solid var(--mono-border);
  background: #ffffff;
}

.curation-tab {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  background: transparent;
  border: none;
  border-right: 1px solid var(--mono-border-light);
  font-family: var(--font-mono);
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--mono-text-primary);
  cursor: pointer;
  transition: all var(--ease-smooth);
}

.curation-tab:last-child {
  border-right: none;
}

.curation-tab:hover {
  background: #f0eee6;
}

.curation-tab.active {
  background: var(--mono-surface-contrast);
  color: #ffffff;
}

.tab-num {
  font-size: 0.72rem;
  opacity: 0.7;
}

.tab-badge {
  font-size: 0.68rem;
  padding: 2px 6px;
  border-radius: 2px;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.tab-badge.mono {
  background: #262626;
  color: #fff;
}
.curation-tab.active .tab-badge.mono {
  background: #ffffff;
  color: #000;
}

.tab-badge.color {
  background: linear-gradient(135deg, #7092b0, #448fd9);
  color: #fff;
}

/* 뷰 모드 토글 버튼 */
.view-mode-toggle {
  display: flex;
  border: 2px solid var(--mono-border);
  background: #ffffff;
}

.mode-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: none;
  background: transparent;
  font-family: var(--font-mono);
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--mono-text-primary);
  cursor: pointer;
  transition: all var(--ease-smooth);
}

.mode-btn:first-child {
  border-right: 1px solid var(--mono-border-light);
}

.mode-btn:hover {
  background: #f0eee6;
}

.mode-btn.active {
  background: var(--mono-surface-contrast);
  color: #fff;
}

.mode-btn svg {
  width: 16px;
  height: 16px;
}

/* 인터랙션 가이드라인 안내 바 */
.interactive-guideline-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 18px;
  background: rgba(0, 0, 0, 0.04);
  border: 1px dashed var(--mono-border);
  font-size: 0.85rem;
  color: var(--mono-text-primary);
  flex-wrap: wrap;
}

.guide-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.guide-icon {
  font-family: var(--font-mono);
  font-weight: 900;
  background: #000;
  color: #fff;
  padding: 1px 7px;
  border-radius: 2px;
  font-size: 0.78rem;
}

.guide-divider {
  color: #b0b0b0;
}

/* ==========================================================================
   2. 2D 에디토리얼 그리드 뷰 (REFERENCE AESTHETIC GRID)
   ========================================================================== */
.grid-view-section {
  display: flex;
  flex-direction: column;
  gap: 56px;
}

.editorial-block-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* 섹션 라벨 바 */
.section-label-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid var(--mono-border);
  padding-bottom: 10px;
}

.label-left {
  display: flex;
  align-items: baseline;
  gap: 14px;
}

.label-code {
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
}

.label-dash {
  font-weight: 900;
  font-size: 1.2rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

.section-tag-mono {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 800;
  background: #000;
  color: #fff;
  padding: 3px 8px;
}

.section-tag-color {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 800;
  background: linear-gradient(135deg, #7092b0, #448fd9);
  color: #fff;
  padding: 3px 8px;
}

.count-tag {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--mono-text-secondary);
}

/* 2D 에디토리얼 그리드 레이아웃 (비대칭 모듈러) */
.editorial-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--grid-gap);
  position: relative;
}

/* 그리드 셀 (각 카드의 독립된 안전 영역 - 충돌 방지 공간) */
.grid-cell {
  position: relative;
  background: transparent;
  min-height: 380px;
  overflow: visible;
}

/* 모듈 크기 분할 (스위스 에디토리얼 비대칭 배치) */
.cell-span-6 { grid-column: span 6; }
.cell-span-4 { grid-column: span 4; }
.cell-span-8 { grid-column: span 8; }
.cell-span-3 { grid-column: span 3; }
.cell-span-12 { grid-column: span 12; }

/* ==========================================================================
   3. 인터랙티브 드래그 카드 (상·하·좌·우 1방향 이동 & 무충돌)
   ========================================================================== */
.interactive-card {
  position: relative;
  width: 100%;
  height: 100%;
  background: var(--mono-surface);
  border: 2px solid var(--mono-border);
  box-shadow: 6px 6px 0px rgba(0, 0, 0, 0.95);
  cursor: grab;
  user-select: none;
  touch-action: none;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  will-change: transform;
  /* 기본 복귀 시 부드러운 스프링 이징 */
  transition: transform 0.45s var(--ease-bounce-back), box-shadow 0.25s ease;
}

/* 드래그 중인 상태 */
.interactive-card.is-dragging {
  cursor: grabbing !important;
  z-index: 50;
  box-shadow: 12px 14px 28px rgba(0, 0, 0, 0.35);
  transition: none !important; /* 드래그 중에는 즉각 반응 */
}

/* 마우스 이탈 시 제자리 복귀 애니메이션 */
.interactive-card.returning {
  transition: transform 0.45s var(--ease-bounce-back) !important;
  transform: translate3d(0px, 0px, 0px) !important;
}

/* 드래그 방향 안내 뱃지 (실시간 표시) */
.drag-direction-indicator {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 30;
  background: #000;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 800;
  padding: 4px 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 0;
  transform: translateY(-6px);
  transition: all 0.2s ease;
  pointer-events: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.interactive-card.is-dragging .drag-direction-indicator {
  opacity: 1;
  transform: translateY(0);
}

/* 카드 상단 에디토리얼 헤더 바 */
.card-top-tagbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  border-bottom: 1px solid var(--mono-border);
  background: #fff;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 800;
}

.big-display-num {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 900;
  line-height: 1;
}

.top-tag-text {
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* 이미지 래퍼 */
.card-media-wrapper {
  position: relative;
  flex: 1;
  width: 100%;
  min-height: 280px;
  max-height: 520px;
  background: #0a0a0a;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-media-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
  transition: filter 0.3s ease;
}

/* 에디토리얼 오버레이 박스 (참고 이미지 스타일 재현) */
.editorial-overlay-box {
  position: absolute;
  bottom: 14px;
  left: 14px;
  background: #ffffff;
  color: #000000;
  padding: 8px 14px;
  border: 2px solid #000000;
  box-shadow: 4px 4px 0px #000000;
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: 2px;
  pointer-events: none;
}

.overlay-super {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #555;
}

.overlay-main {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.1;
  text-transform: uppercase;
}

.overlay-dash {
  font-weight: 900;
  font-size: 1rem;
  margin-top: 2px;
}

/* 카드 하단 메타 바 */
.card-bottom-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #ffffff;
  border-top: 1px solid var(--mono-border);
}

.card-title-group {
  display: flex;
  flex-direction: column;
}

.card-title {
  font-size: 0.96rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #000;
}

.card-specs {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #666;
}

.card-inspect-hint {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 800;
  background: #000;
  color: #fff;
  padding: 5px 10px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* ==========================================================================
   4. 사진 섹션 전용 컬러 스타일 (사진 고유 색상 기반)
   ========================================================================== */
.block-photos {
  background: var(--photo-bg);
  color: var(--photo-text-primary);
  padding: 32px;
  border: 2px solid #000;
  box-shadow: 8px 8px 0px rgba(0, 0, 0, 0.95);
  margin-top: 24px;
}

.block-photos .section-label-bar {
  border-bottom-color: var(--photo-border);
}

.block-photos .label-code,
.block-photos .section-title,
.block-photos .label-dash {
  color: #ffffff;
}

.block-photos .count-tag {
  color: #94a3b8;
}

/* 사진 카드 스타일 */
.photo-card {
  background: var(--photo-surface);
  border: 1px solid var(--photo-border);
  box-shadow: 6px 6px 0px rgba(0, 0, 0, 0.6);
}

.photo-card .card-top-tagbar {
  background: #11141a;
  border-bottom-color: var(--photo-border);
  color: #f1f5f9;
}

.photo-card .big-display-num {
  color: var(--photo-accent-cyan);
}

.photo-card .editorial-overlay-box {
  background: rgba(15, 18, 23, 0.92);
  color: #ffffff;
  border: 1px solid var(--photo-border);
  box-shadow: 4px 4px 0px rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
}

.photo-card .overlay-super {
  color: #94a3b8;
}

.photo-card .card-bottom-bar {
  background: #11141a;
  border-top-color: var(--photo-border);
}

.photo-card .card-title {
  color: #f8fafc;
}

.photo-card .card-specs {
  color: #94a3b8;
}

/* 사진 고유 색상 팔레트 스와치 칩 (Extracted Color Swatch) */
.color-swatch-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 3px 8px;
  border-radius: 2px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: #e2e8f0;
}

.swatch-color-dot {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 6px currentColor;
}

/* ==========================================================================
   5. 시네마틱 슬라이더 뷰 (선택형 뷰 모드)
   ========================================================================== */
.slider-view-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.slider-view-section.hidden {
  display: none !important;
}

.slider-viewport {
  position: relative;
  height: 64vh;
  min-height: 480px;
  background: #000;
  border: 2px solid var(--mono-border);
  box-shadow: 8px 8px 0px rgba(0, 0, 0, 0.95);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.slider-canvas {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30px;
}

.slider-image-wrapper {
  position: relative;
  max-width: 100%;
  max-height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

#sliderMainImage {
  max-width: 100%;
  max-height: 58vh;
  object-fit: contain;
  transition: opacity 0.25s ease;
}

.slider-zoom-hint {
  position: absolute;
  bottom: 20px;
  background: #fff;
  color: #000;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 800;
  padding: 6px 14px;
  border: 2px solid #000;
  box-shadow: 4px 4px 0px #000;
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.25s ease;
  pointer-events: none;
}

.slider-image-wrapper:hover .slider-zoom-hint {
  opacity: 1;
  transform: translateY(0);
}

.nav-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  width: 52px;
  height: 72px;
  background: #fff;
  color: #000;
  border: 2px solid #000;
  box-shadow: 4px 4px 0px #000;
  font-size: 2.2rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease, background 0.15s ease;
}

.prev-arrow { left: 24px; }
.next-arrow { right: 24px; }

.nav-arrow:hover {
  background: #000;
  color: #fff;
  transform: translateY(-50%) scale(1.05);
}

.slider-progress-track {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 5px;
  background: rgba(255, 255, 255, 0.15);
}

.slider-progress-bar {
  width: 0%;
  height: 100%;
  background: #fff;
}

/* 슬라이더 하단 바 */
.slider-bottom-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: #fff;
  border: 2px solid var(--mono-border);
  box-shadow: 6px 6px 0px rgba(0, 0, 0, 0.95);
  flex-wrap: wrap;
  gap: 16px;
}

.slider-badge-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.slider-cat-pill {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 800;
  background: #000;
  color: #fff;
  padding: 2px 8px;
}

.slider-counter {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  color: #666;
}

.slider-title {
  font-size: 1.35rem;
  font-weight: 900;
  margin-top: 4px;
}

.slider-specs {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: #666;
}

.slider-actions {
  display: flex;
  gap: 10px;
}

.slider-btn {
  display: inline-flex;
  align-items: center;
  padding: 10px 18px;
  background: #fff;
  color: #000;
  border: 2px solid #000;
  box-shadow: 3px 3px 0px #000;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
}

.slider-btn.primary {
  background: #000;
  color: #fff;
}

.slider-btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0px #000;
}

/* 썸네일 스트립 */
.slider-thumb-reel {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 8px 4px;
}

.slider-thumb-item {
  width: 100px;
  height: 70px;
  border: 2px solid var(--mono-border);
  box-shadow: 3px 3px 0px rgba(0, 0, 0, 0.8);
  flex-shrink: 0;
  cursor: pointer;
  overflow: hidden;
  background: #000;
  opacity: 0.65;
  transition: all 0.2s ease;
}

.slider-thumb-item.active,
.slider-thumb-item:hover {
  opacity: 1;
  border-color: #000;
  transform: translateY(-3px);
  box-shadow: 5px 5px 0px rgba(0, 0, 0, 0.95);
}

.slider-thumb-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ==========================================================================
   6. 정밀 확대/축소 뷰어 모달 (LightBox Zoom & Pan)
   ========================================================================== */
.zoom-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 99999;
  display: none;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

.zoom-modal.open {
  display: block;
  opacity: 1;
  pointer-events: auto;
}

.zoom-modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(8, 8, 10, 0.95);
  backdrop-filter: blur(16px);
}

.zoom-top-bar {
  position: absolute;
  top: 20px;
  left: 24px;
  right: 24px;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 18px;
  background: #ffffff;
  border: 2px solid #000;
  box-shadow: 5px 5px 0px #000;
}

.zoom-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.zoom-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 800;
  background: #000;
  color: #fff;
  padding: 3px 8px;
}

.zoom-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: #000;
}

.zoom-res {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: #555;
}

.zoom-actions {
  display: flex;
  gap: 8px;
}

.zoom-top-btn {
  padding: 7px 14px;
  background: #fff;
  border: 2px solid #000;
  box-shadow: 2px 2px 0px #000;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.15s ease;
}

.zoom-top-btn:hover {
  background: #000;
  color: #fff;
}

.modal-nav-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 90;
  width: 48px;
  height: 70px;
  background: #fff;
  border: 2px solid #000;
  box-shadow: 4px 4px 0px #000;
  font-size: 2.2rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-prev { left: 20px; }
.modal-next { right: 20px; }

.modal-nav-arrow:hover {
  background: #000;
  color: #fff;
}

.zoom-viewport {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
}

.zoom-viewport.dragging {
  cursor: grabbing !important;
}

.zoom-target {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transform-origin: center center;
  will-change: transform;
  transition: transform 0.12s var(--ease-smooth);
}

.zoom-viewport.dragging .zoom-target {
  transition: none !important;
}

#zoomImage {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8);
  pointer-events: none;
}

/* 미니맵 */
.zoom-minimap {
  position: absolute;
  bottom: 84px;
  right: 24px;
  z-index: 100;
  background: #fff;
  border: 2px solid #000;
  box-shadow: 5px 5px 0px #000;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.zoom-minimap.hidden {
  display: none !important;
}

.minimap-box {
  position: relative;
  width: 150px;
  height: 110px;
  background: #000;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

#minimapImage {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  opacity: 0.65;
}

.minimap-rect {
  position: absolute;
  border: 2px solid #ef4444;
  background: rgba(239, 68, 68, 0.25);
  pointer-events: none;
}

.minimap-text {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 800;
  text-align: center;
}

/* 줌 하단 플로팅 컨트롤 바 */
.zoom-dock {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: #ffffff;
  border: 2px solid #000;
  box-shadow: 5px 5px 0px #000;
}

.dock-btn {
  width: 36px;
  height: 36px;
  background: #fff;
  border: 2px solid #000;
  font-size: 1.2rem;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dock-btn:hover {
  background: #000;
  color: #fff;
}

.dock-text-btn {
  padding: 7px 12px;
  background: #fff;
  border: 2px solid #000;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 800;
  cursor: pointer;
}

.dock-text-btn:hover,
.dock-text-btn.active {
  background: #000;
  color: #fff;
}

.dock-sep {
  width: 1px;
  height: 22px;
  background: #ccc;
  margin: 0 4px;
}

.dock-slider-wrap {
  width: 100px;
}

#zoomRangeInput {
  width: 100%;
  accent-color: #000;
  cursor: pointer;
}

.dock-percent {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 800;
  min-width: 46px;
  text-align: center;
}

.zoom-shortcut-tip {
  position: absolute;
  top: 76px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 90;
  background: #000;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  padding: 4px 12px;
  pointer-events: none;
}

/* ==========================================================================
   7. 푸터
   ========================================================================== */
.editorial-footer {
  border-top: 2px solid var(--mono-border);
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.footer-bold {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 900;
}

.footer-sub {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--mono-text-secondary);
}

.footer-shortcuts {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.shortcut-pill {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  background: #fff;
  border: 1px solid var(--mono-border);
  padding: 3px 8px;
}

/* ==========================================================================
   8. 반응형 대응 (Responsive)
   ========================================================================== */
@media (max-width: 1200px) {
  .cell-span-6 { grid-column: span 6; }
  .cell-span-4 { grid-column: span 6; }
  .cell-span-8 { grid-column: span 12; }
  .cell-span-3 { grid-column: span 6; }
}

@media (max-width: 768px) {
  .portfolio-wrapper {
    padding: 16px;
  }
  .main-headline {
    font-size: 2.2rem;
  }
  .editorial-grid {
    grid-template-columns: 1fr;
  }
  .cell-span-6,
  .cell-span-4,
  .cell-span-8,
  .cell-span-3,
  .cell-span-12 {
    grid-column: span 1;
  }
  .zoom-dock {
    width: 94%;
    justify-content: space-around;
  }
  .dock-slider-wrap {
    display: none;
  }
  .zoom-minimap {
    display: none;
  }
}
