/* ==========================================================================
   mncaw.css - CAW 모바일 계층형 트리 메뉴 & 기사 편집 시스템 (/m/css/mncaw.css)
   mcaw.htm 모바일용 기사편집페이지 디자인 적용 + 스마트폰 화면폭 최적화
   ========================================================================== */

*, *::before, *::after {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  min-height: 100%;
  background-color: #f1f5f9; /* 모바일 앱 스타일 소프트 그레이 */
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans KR", sans-serif;
  color: #0f172a;
  -webkit-text-size-adjust: 100%;
}

/* 전체 모바일 앱 레이아웃 컨테이너 (스마트폰 및 패블릿 완벽 핏 520px) */
.mobile-app-layout {
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  min-height: 100vh;
  background-color: #ffffff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
  position: relative;
}

/* 1. 모바일 앱 상단 헤더 바 */
.mobile-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-bottom: 2px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.header-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.m-menu-toggle-btn {
  height: 30px;
  padding: 0 9px;
  border-radius: 6px;
  border: 1px solid #cbd5e1;
  background-color: #f8fafc;
  color: #1e293b;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s ease;
}

.m-menu-toggle-btn:active {
  background-color: #e2e8f0;
  transform: scale(0.97);
}

.mobile-brand {
  display: flex;
  align-items: center;
  gap: 6px;
}

.mobile-title {
  font-size: 16px;
  font-weight: 800;
  color: #1e3a8a;
  letter-spacing: -0.3px;
  margin: 0;
}

.site-badge {
  background: #2563eb;
  color: #ffffff !important;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
  text-decoration: none !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.site-badge:hover {
  background: #1d4ed8;
  color: #ffffff !important;
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.4);
}

.auth-badge {
  font-size: 11px;
  color: #475569;
  background: #f8fafc;
  padding: 3px 8px;
  border-radius: 12px;
  border: 1px solid #cbd5e1;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.auth-btn {
  height: 22px;
  padding: 0 7px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #334155;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.12s ease;
}

.auth-btn:hover {
  background: #f1f5f9;
}

.auth-btn-primary {
  background: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
}

.auth-btn-primary:hover {
  background: #1d4ed8;
}

/* 2. 오프캔버스 메뉴 트리 서랍장 (Drawer) */
.drawer-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(3px);
  z-index: 998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.drawer-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
}

.tree-drawer {
  position: fixed;
  top: 0;
  left: 0;
  width: 310px;
  max-width: 86vw;
  height: 100vh;
  background-color: #ffffff;
  z-index: 999;
  transform: translateX(-100%);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
}

.tree-drawer.is-open {
  transform: translateX(0);
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background-color: #1e3a8a;
  color: #ffffff;
}

.drawer-title {
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.drawer-close-btn {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
  font-size: 20px;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.drawer-close-btn:active {
  background: rgba(255, 255, 255, 0.35);
  transform: scale(0.95);
}

.drawer-menu-toolbar {
  padding: 8px 12px;
  background-color: #f1f5f9;
  border-bottom: 1px solid #cbd5e1;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.drawer-menu-toolbar i,
.drawer-menu-toolbar span.brand-text {
  cursor: pointer;
  font-size: 22px !important;
  color: #475569;
  line-height: 1;
  user-select: none;
  transition: color 0.15s ease;
}

.drawer-menu-toolbar i:active {
  color: #2563eb;
}

.drawer-menu-toolbar span.brand-text {
  font-weight: 800;
  font-size: 16px !important;
  color: #1e3a8a;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.drawer-tree-content {
  flex-grow: 1;
  overflow-y: auto;
  padding: 10px 10px 40px 10px;
}

/* 트리 노드 아이템 스타일 */
.tree-node-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 6px;
  min-height: 32px;
  line-height: 1.2;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  color: #1e293b;
  margin-bottom: 3px;
  user-select: none;
  border: 1px solid transparent;
}

.tree-node-item:active {
  background-color: #e2e8f0;
}

.tree-node-item.is-selected {
  background-color: #eff6ff;
  border-color: #bfdbfe;
  color: #1d4ed8;
  font-weight: 700;
}

.tree-node-sub {
  margin-left: 18px;
  border-left: 1px dashed #cbd5e1;
  padding-left: 6px;
}

.tree-node-item .folder-icon {
  font-size: 20px !important;
  line-height: 1;
  flex-shrink: 0;
  width: 22px;
  text-align: center;
}

.tree-node-item .fa-file-text-o {
  font-size: 18px !important;
  line-height: 1;
  flex-shrink: 0;
  width: 20px;
  text-align: center;
}

.node-active-chk {
  width: 18px !important;
  height: 18px !important;
  cursor: pointer;
  margin: 0 4px 0 2px;
  accent-color: #2563eb;
  flex-shrink: 0;
}

.tree-node-item .node-title-text {
  font-size: 13px;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex-grow: 1;
}

.node-action-icon {
  color: #94a3b8;
  font-size: 18px !important;
  padding: 3px 5px;
  border-radius: 4px;
  line-height: 1;
  cursor: pointer;
  margin-left: 2px;
  flex-shrink: 0;
}

.node-action-icon:active {
  color: #ef4444;
  background-color: #fee2e2;
}

/* 3. 모바일 메인 콘텐츠 영역 (mcaw.htm 구조 정합) */
.mobile-main-content {
  padding: 10px 12px 36px 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* 현재 선택된 메뉴 배너 */
.current-menu-banner {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(37, 99, 235, 0.08);
  transition: all 0.15s ease;
}

.current-menu-banner:active {
  background: #dbeafe;
}

.banner-left {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow: hidden;
}

.banner-icon {
  color: #2563eb;
  font-size: 15px;
  flex-shrink: 0;
}

.banner-text {
  font-size: 13px;
  font-weight: 700;
  color: #1e3a8a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.banner-badge {
  font-size: 11px;
  font-weight: 600;
  color: #2563eb;
  background: #ffffff;
  padding: 2px 8px;
  border-radius: 12px;
  border: 1px solid #bfdbfe;
  white-space: nowrap;
  flex-shrink: 0;
}

/* 잠금 안내 카드 */
.guest-lock-card {
  background: #ffffff;
  border: 2px dashed #cbd5e1;
  border-radius: 12px;
  padding: 24px 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.guest-lock-icon {
  font-size: 32px;
  line-height: 1;
}

.guest-lock-title {
  font-size: 15px;
  font-weight: 800;
  color: #1e293b;
  margin: 0;
}

.guest-lock-desc {
  font-size: 12px;
  color: #64748b;
  line-height: 1.5;
  margin: 0;
  max-width: 320px;
}

.guest-lock-btns {
  display: flex;
  gap: 8px;
  margin-top: 6px;
  width: 100%;
  max-width: 260px;
}

.guest-lock-btns .m-btn {
  flex: 1;
}

/* 버튼 공통 스타일 (mcaw.css 터치 규격 일치) */
.m-btn {
  height: 32px;
  padding: 0 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  transition: all 0.15s ease;
  white-space: nowrap;
  user-select: none;
}

.m-btn:active {
  transform: scale(0.97);
}

.m-btn:disabled,
.m-btn[disabled],
.m-btn.is-disabled {
  opacity: 0.45 !important;
  cursor: not-allowed !important;
  pointer-events: none !important;
  box-shadow: none !important;
  transform: none !important;
  filter: grayscale(35%) !important;
}


.m-btn-blue {
  background-color: #2563eb;
  color: #ffffff;
}
.m-btn-blue:hover {
  background-color: #1d4ed8;
}

.m-btn-red {
  background-color: #ef4444;
  color: #ffffff;
}
.m-btn-red:hover {
  background-color: #dc2626;
}

.m-btn-green {
  background-color: #10b981;
  color: #ffffff;
}
.m-btn-green:hover {
  background-color: #059669;
}

.m-btn-gray {
  background-color: #64748b;
  color: #ffffff;
}
.m-btn-gray:hover {
  background-color: #475569;
}

.m-btn-subtle {
  background-color: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
}

/* 4. 모바일 기사 목록 및 일괄 관리 바 (mcaw.css 일치) */
.list-card {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.list-toolbar {
  padding: 6px 8px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.toolbar-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.toolbar-bottom-row {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  flex-wrap: nowrap;
}

.m-target-input {
  min-width: 65px;
  max-width: 120px;
  height: 28px;
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #ffffff;
  outline: none;
  padding: 0 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.m-target-input:focus {
  border-color: #2563eb;
}

.m-select {
  height: 28px;
  padding: 0 6px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background-color: #ffffff;
  font-size: 12px;
  color: #1e293b;
  outline: none;
}

/* 타이트한 기사 테이블 (mcaw.css 26px 줄간격) */
.table-scroll-container {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

#newsTable {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  line-height: 1.2;
}

#newsTable thead tr {
  background-color: #f1f5f9;
  border-bottom: 1px solid #cbd5e1;
  height: 28px;
}

#newsTable th {
  padding: 3px 4px;
  color: #475569;
  font-weight: 700;
  text-align: center;
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
}

#newsTable tbody tr {
  height: 26px; /* 26px 타이트 줄간격 */
  border-bottom: 1px solid #f1f5f9;
  cursor: pointer;
  transition: background-color 0.12s ease;
}

#newsTable tbody tr:hover,
#newsTable tbody tr:active {
  background-color: #f8fafc;
}

#newsTable tbody tr.is-selected {
  background-color: #eff6ff !important;
  font-weight: 700;
  color: #1d4ed8;
}

#newsTable td {
  padding: 2px 4px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
  line-height: 1.25;
}

#newsTable th.th-title,
#newsTable th:nth-child(3),
#newsTable td.title-cell,
#newsTable td:nth-child(3),
#newsTable td.td-title,
.title-cell {
  text-align: left !important;
  padding-left: 8px !important;
  max-width: 180px;
}

.row-chk, .pub-chk {
  width: 15px;
  height: 15px;
  cursor: pointer;
  accent-color: #2563eb;
  vertical-align: middle;
  margin: 0 auto;
  display: block;
}

/* ==========================================================================
   5. [핵심] mcaw.htm 기사 편집 컨트롤 카드 디자인 완벽 적용 & 스마트폰 최적화
   ========================================================================== */
.editor-action-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
}

/* 스마트폰 폭에 꼭 맞춘 메타 태그 라인 */
.meta-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  width: 100%;
}

.meta-capsule {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: #f8fafc;
  padding: 3px 6px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  font-size: 11px;
  color: #475569;
  font-weight: 600;
  flex: 1;
  min-width: 0;
}

.meta-capsule input {
  width: 42px;
  height: 24px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  background: #ffffff;
  color: #1e293b;
  outline: none;
}

.meta-capsule select {
  width: auto;
  max-width: 78px;
  height: 24px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  background: #ffffff;
  font-size: 11px;
  color: #1e293b;
  outline: none;
  padding: 0 2px;
}

/* 엄지 터치 최적화 3분할 액션 버튼 그리드 (mcaw.htm 동일) */
.main-action-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 6px;
  width: 100%;
}

.main-action-buttons .m-btn {
  height: 38px; /* 주요 작업 버튼 높이 확보 (엄지 터치 최적화) */
  font-size: 13px;
  font-weight: 700;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

/* 제목 및 부제목 입력 필드 (mcaw.htm 동일) */
.m-input-group {
  display: flex;
  flex-direction: column;
  gap: 3px;
  width: 100%;
}

.m-input-label {
  font-size: 12px;
  font-weight: 700;
  color: #334155;
  margin-left: 2px;
}

.m-text-input {
  width: 100%;
  height: 38px; /* 터치 및 타이핑 편의 */
  padding: 0 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background-color: #ffffff;
  font-size: 14px; /* iOS 자동 줌 방지 적정 폰트 */
  color: #0f172a;
  outline: none;
  transition: all 0.15s ease;
}

.m-text-input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

/* 6. 모바일 웹에디터 마운트 영역 (mcaw.htm 동일) */
.editor-mount-wrapper {
  width: 100%;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  overflow: hidden;
  background: #ffffff;
}

.editor-wrapper-container {
  width: 100%;
}

/* 모바일 상태 알림 토스트 (mcaw.htm 동일) */
#result {
  min-height: 28px;
  font-size: 12px;
  font-weight: 600;
  color: #1d4ed8;
  padding: 6px 10px;
  background: #eff6ff;
  border-radius: 8px;
  border: 1px solid #bfdbfe;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  word-break: break-all;
}

/* 7. 사용자 인증(로그인/회원가입) 모달 */
.m-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(2px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.m-modal-backdrop.is-active {
  display: flex;
}

.m-modal-card {
  width: 100%;
  max-width: 360px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  animation: modalFadeIn 0.2s ease-out;
}

@keyframes modalFadeIn {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.m-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}

.m-modal-title {
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
}

.m-modal-close {
  background: none;
  border: none;
  font-size: 20px;
  color: #64748b;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.m-modal-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.m-modal-footer {
  padding: 0 16px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: center;
}

.modal-error-msg {
  color: #ef4444;
  font-size: 11px;
  font-weight: 600;
}

/* ==========================================================================
   인스타그램 / 릴스 뷰어 3대 버튼 모던 글래스모피즘 디자인
   ========================================================================== */
.instagram-overlay-header {
  width: 100% !important;
  height: 50px !important;
  min-height: 46px !important;
  padding: 8px 12px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 6px !important;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.55) 0%, rgba(0, 0, 0, 0.15) 75%, transparent 100%) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border-top-left-radius: 8px !important;
  border-top-right-radius: 8px !important;
  box-sizing: border-box !important;
  pointer-events: auto;
  position: relative !important;
  z-index: 5 !important;
}

.instagram-play-mode-btn,
.instagram-toggle-type-btn,
.instagram-view-btn {
  height: 28px !important;
  line-height: 28px !important;
  padding: 0 10px !important;
  border-radius: 20px !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  letter-spacing: -0.2px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 5px !important;
  color: #ffffff !important;
  background: rgba(15, 23, 42, 0.65) !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  cursor: pointer !important;
  pointer-events: auto;
  text-decoration: none !important;
  white-space: nowrap !important;
  user-select: none !important;
  box-sizing: border-box !important;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.instagram-play-mode-btn svg,
.instagram-toggle-type-btn svg,
.instagram-view-btn svg {
  flex-shrink: 0 !important;
  display: block !important;
}

.instagram-play-mode-btn {
  background: rgba(15, 23, 42, 0.68) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
}

.instagram-play-mode-btn svg {
  fill: #f43f5e !important;
}

.instagram-play-mode-btn:hover {
  background: rgba(225, 48, 108, 0.88) !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
  color: #ffffff !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(225, 48, 108, 0.35) !important;
}

.instagram-play-mode-btn:hover svg {
  fill: #ffffff !important;
}

.instagram-play-mode-btn:active {
  transform: scale(0.96) !important;
}

.instagram-play-mode-btn.is-active {
  background: rgba(22, 163, 74, 0.88) !important;
  border-color: rgba(34, 197, 94, 0.5) !important;
}

.instagram-play-mode-btn.is-active svg {
  stroke: #ffffff !important;
  fill: none !important;
}

.instagram-play-mode-btn.is-active:hover {
  background: rgba(21, 128, 61, 0.95) !important;
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.35) !important;
}

.instagram-toggle-type-btn {
  background: rgba(15, 23, 42, 0.65) !important;
  color: #f1f5f9 !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  margin-left: 0 !important;
  margin-right: auto !important;
}

.instagram-toggle-type-btn svg {
  stroke: #94a3b8 !important;
}

.instagram-toggle-type-btn:hover {
  background: rgba(30, 41, 59, 0.88) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
}

.instagram-toggle-type-btn:hover svg {
  stroke: #ffffff !important;
}

.instagram-toggle-type-btn:active {
  transform: scale(0.96) !important;
}

.instagram-view-btn {
  background: rgba(15, 23, 42, 0.65) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  margin-left: auto !important;
}

.instagram-view-btn svg:first-child {
  stroke: #f43f5e !important;
}

.instagram-view-btn svg:last-child {
  stroke: #94a3b8 !important;
}

.instagram-view-btn:hover {
  background: linear-gradient(135deg, rgba(240, 148, 51, 0.9) 0%, rgba(225, 48, 108, 0.9) 50%, rgba(188, 24, 136, 0.9) 100%) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.45) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 14px rgba(225, 48, 108, 0.4) !important;
}

.instagram-view-btn:hover svg:first-child,
.instagram-view-btn:hover svg:last-child {
  stroke: #ffffff !important;
}

.instagram-view-btn:active {
  transform: scale(0.96) !important;
}

body.rte-resizing .instagram-overlay,
body.rte-resizing .instagram-overlay *,
body.rte-resizing .instagram-overlay-header,
body.rte-resizing .instagram-play-mode-btn,
body.rte-resizing .instagram-toggle-type-btn,
body.rte-resizing .instagram-view-btn,
body.rte-resizing .instagram-play-toggle-btn,
body.rte-resizing .instagram-container iframe {
  pointer-events: none !important;
}
body.rte-resizing .rte-corner-handle {
  pointer-events: auto !important;
}

/* ==========================================================================
   인터넷 신문 추천 구글 웹폰트 14종 (한글 7종, 영문 5종, 영문 필기체 2종)
   ========================================================================== */
.font-noto-sans, [data-font="Noto Sans KR"] { font-family: 'Noto Sans KR\, -apple-system, sans-serif !important; }
.font-noto-serif, [data-font="Noto Serif KR"] { font-family: 'Noto Serif KR\, serif !important; }
.font-nanum-gothic, [data-font="Nanum Gothic"] { font-family: 'Nanum Gothic\, sans-serif !important; }
.font-nanum-myeongjo, [data-font="Nanum Myeongjo"] { font-family: 'Nanum Myeongjo\, serif !important; }
.font-gowun-batang, [data-font="Gowun Batang"] { font-family: 'Gowun Batang\, serif !important; }
.font-gowun-dodum, [data-font="Gowun Dodum"] { font-family: 'Gowun Dodum\, sans-serif !important; }
.font-song-myung, [data-font="Song Myung"] { font-family: 'Song Myung\, serif !important; }
.font-roboto, [data-font="Roboto"] { font-family: 'Roboto\, sans-serif !important; }
.font-merriweather, [data-font="Merriweather"] { font-family: 'Merriweather\, serif !important; }
.font-playfair, [data-font="Playfair Display"] { font-family: 'Playfair Display\, serif !important; }
.font-lora, [data-font="Lora"] { font-family: 'Lora\, serif !important; }
.font-montserrat, [data-font="Montserrat"] { font-family: 'Montserrat\, sans-serif !important; }
.font-dancing-script, [data-font="Dancing Script"] { font-family: 'Dancing Script\, cursive !important; }
.font-great-vibes, [data-font="Great Vibes"] { font-family: 'Great Vibes\, cursive !important; }
font[face="Noto Sans KR"], font[face="Noto Sans"] { font-family: 'Noto Sans KR\, sans-serif; }
font[face="Noto Serif KR"], font[face="Noto Serif"] { font-family: 'Noto Serif KR\, serif; }
font[face="Nanum Gothic"] { font-family: 'Nanum Gothic\, sans-serif; }
font[face="Nanum Myeongjo"] { font-family: 'Nanum Myeongjo\, serif; }
font[face="Gowun Batang"] { font-family: 'Gowun Batang\, serif; }
font[face="Gowun Dodum"] { font-family: 'Gowun Dodum\, sans-serif; }
font[face="Song Myung"] { font-family: 'Song Myung\, serif; }
font[face="Roboto"] { font-family: 'Roboto\, sans-serif; }
font[face="Merriweather"] { font-family: 'Merriweather\, serif; }
font[face="Playfair Display"] { font-family: 'Playfair Display\, serif; }
font[face="Lora"] { font-family: 'Lora\, serif; }
font[face="Montserrat"] { font-family: 'Montserrat\, sans-serif; }
font[face="Dancing Script"] { font-family: 'Dancing Script\, cursive; }
font[face="Great Vibes"] { font-family: 'Great Vibes\, cursive; }


    /* [v3.99 모바일 헤더 조화로운 2단 일체형 리디자인] */
    .mobile-header {
      position: sticky !important;
      top: 0 !important;
      z-index: 100 !important;
      background-color: #ffffff !important;
      display: flex !important;
      flex-direction: column !important;
      align-items: stretch !important;
      gap: 6px !important;
      padding: 8px 10px !important;
      border-bottom: 2px solid #e2e8f0 !important;
      box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03) !important;
      width: 100% !important;
      box-sizing: border-box !important;
    }
    .mobile-header-main {
      display: flex !important;
      align-items: center !important;
      justify-content: space-between !important;
      width: 100% !important;
      gap: 8px !important;
      flex-wrap: nowrap !important;
    }
    .header-left {
      display: inline-flex !important;
      align-items: center !important;
      gap: 6px !important;
      white-space: nowrap !important;
      flex-shrink: 0 !important;
    }
    .m-menu-toggle-btn {
      height: 28px !important;
      padding: 0 8px !important;
      border-radius: 6px !important;
      border: 1px solid #cbd5e1 !important;
      background-color: #f8fafc !important;
      color: #1e293b !important;
      font-size: 11.5px !important;
      font-weight: 700 !important;
      cursor: pointer !important;
      display: inline-flex !important;
      align-items: center !important;
      gap: 4px !important;
      white-space: nowrap !important;
      flex-shrink: 0 !important;
      transition: all 0.15s ease !important;
    }
    .m-menu-toggle-btn span {
      white-space: nowrap !important;
      display: inline-block !important;
    }
    .mobile-brand {
      display: inline-flex !important;
      align-items: center !important;
      gap: 5px !important;
      white-space: nowrap !important;
      flex-shrink: 0 !important;
    }
    .brand-logo-link {
      text-decoration: none !important;
      color: inherit !important;
      display: inline-flex !important;
      align-items: center !important;
    }
    .mobile-title {
      font-size: 16px !important;
      font-weight: 800 !important;
      color: #1e3a8a !important;
      letter-spacing: -0.3px !important;
      margin: 0 !important;
      white-space: nowrap !important;
    }
    .site-badge {
      background: #2563eb !important;
      color: #ffffff !important;
      font-size: 10.5px !important;
      font-weight: 700 !important;
      padding: 2px 7px !important;
      border-radius: 10px !important;
      text-decoration: none !important;
      white-space: nowrap !important;
      flex-shrink: 0 !important;
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
    }
    .mobile-auth-wrap {
      display: inline-flex !important;
      align-items: center !important;
      flex-shrink: 0 !important;
    }
    .auth-badge {
      font-size: 11.5px !important;
      color: #334155 !important;
      background: #f8fafc !important;
      padding: 3px 8px !important;
      border-radius: 9999px !important;
      border: 1px solid #cbd5e1 !important;
      font-weight: 600 !important;
      display: inline-flex !important;
      align-items: center !important;
      gap: 6px !important;
      white-space: nowrap !important;
      flex-shrink: 0 !important;
      box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
    }
    .auth-btn {
      height: 22px !important;
      padding: 0 8px !important;
      border-radius: 5px !important;
      font-size: 11px !important;
      font-weight: 700 !important;
      border: 1px solid #cbd5e1 !important;
      background: #ffffff !important;
      color: #475569 !important;
      cursor: pointer !important;
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
      white-space: nowrap !important;
      flex-shrink: 0 !important;
      transition: all 0.15s ease !important;
    }
    .auth-btn:hover {
      background: #fee2e2 !important;
      color: #dc2626 !important;
      border-color: #fca5a5 !important;
    }
    .auth-btn-primary {
      background: #2563eb !important;
      color: #ffffff !important;
      border-color: #2563eb !important;
    }
    .mobile-admin-bar {
      display: none !important;
      flex-direction: column !important;
      gap: 5px !important;
      background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%) !important;
      border: 1px solid #e2e8f0 !important;
      border-radius: 8px !important;
      padding: 6px 8px !important;
      width: 100% !important;
      box-sizing: border-box !important;
      box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04) !important;
    }
    .mobile-admin-bar.is-admin-active {
      display: flex !important;
    }
    .mobile-admin-row {
      display: none !important;
      align-items: center !important;
      flex-wrap: wrap !important;
      gap: 5px !important;
      width: 100% !important;
    }
    .mobile-admin-bar.is-admin-active .mobile-admin-row {
      display: flex !important;
    }
    .admin-bar-label {
      font-size: 11px !important;
      font-weight: 700 !important;
      color: #1e3a8a !important;
      display: inline-flex !important;
      align-items: center !important;
      gap: 3px !important;
      user-select: none !important;
      white-space: nowrap !important;
      flex-shrink: 0 !important;
      margin-right: 1px !important;
    }
    .admin-bar-label-sub {
      color: #475569 !important;
    }
    .m-header-db-btn {
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
      gap: 4px !important;
      height: 25px !important;
      padding: 0 8px !important;
      font-size: 11px !important;
      font-weight: 700 !important;
      border-radius: 5px !important;
      border: 1px solid #cbd5e1 !important;
      background-color: #ffffff !important;
      color: #334155 !important;
      cursor: pointer !important;
      transition: all 0.15s ease !important;
      white-space: nowrap !important;
      text-decoration: none !important;
      flex-shrink: 0 !important;
      box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
    }
    .btn-db-backup {
      border-color: #cbd5e1 !important;
      color: #1e3a8a !important;
    }
    .btn-db-backup:hover {
      background-color: #eff6ff !important;
      border-color: #93c5fd !important;
      color: #1d4ed8 !important;
    }
    .btn-db-restore {
      border-color: #fcd34d !important;
      color: #b45309 !important;
      background-color: #fffbeb !important;
    }
    .btn-db-restore:hover {
      background-color: #fef3c7 !important;
      border-color: #f59e0b !important;
      color: #92400e !important;
    }
    .btn-site-design {
      border-color: #1d4ed8 !important;
      background-color: #2563eb !important;
      color: #ffffff !important;
    }
    .btn-site-design:hover {
      background-color: #1d4ed8 !important;
    }
    .upload-limit-input-wrap {
      display: inline-flex !important;
      align-items: center !important;
      background: #ffffff !important;
      border: 1px solid #cbd5e1 !important;
      border-radius: 5px !important;
      padding: 0 5px !important;
      height: 25px !important;
      box-sizing: border-box !important;
      flex-shrink: 0 !important;
    }
    .upload-limit-input-wrap input {
      width: 42px !important;
      border: none !important;
      outline: none !important;
      font-size: 11px !important;
      font-weight: 700 !important;
      text-align: right !important;
      color: #0f172a !important;
      padding: 0 !important;
      background: transparent !important;
    }
    .upload-limit-unit {
      font-size: 10.5px !important;
      font-weight: 600 !important;
      color: #64748b !important;
      margin-left: 2px !important;
    }
    .upload-limit-select {
      height: 25px !important;
      font-size: 11px !important;
      font-weight: 600 !important;
      border: 1px solid #cbd5e1 !important;
      border-radius: 5px !important;
      background: #ffffff !important;
      color: #334155 !important;
      cursor: pointer !important;
      padding: 0 4px !important;
      flex-shrink: 0 !important;
    }
    .m-header-save-btn {
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
      height: 25px !important;
      padding: 0 8px !important;
      font-size: 11px !important;
      font-weight: 700 !important;
      border-radius: 5px !important;
      border: 1px solid #1d4ed8 !important;
      background-color: #2563eb !important;
      color: #ffffff !important;
      cursor: pointer !important;
      transition: all 0.15s ease !important;
      white-space: nowrap !important;
      flex-shrink: 0 !important;
    }
    .m-header-save-btn:hover {
      background-color: #1d4ed8 !important;
    }


/* [v4.00] 신규 기자 승인 및 회원 관리 모달 스타일 */
.btn-user-approval {
  border-color: #cbd5e1 !important;
  color: #0f766e !important;
  background-color: #f0fdfa !important;
}
.btn-user-approval:hover {
  background-color: #ccfbf1 !important;
  border-color: #14b8a6 !important;
  color: #0f766e !important;
}
.pending-badge {
  background: #ea580c !important;
  color: #ffffff !important;
  border-radius: 9999px !important;
  padding: 1px 6px !important;
  font-size: 10px !important;
  font-weight: 800 !important;
  margin-left: 3px !important;
}
.user-modal-card {
  max-width: 960px !important;
  width: 95% !important;
  max-height: 90vh !important;
  display: flex !important;
  flex-direction: column !important;
}
.user-modal-toolbar {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 10px 16px !important;
  background: #f8fafc !important;
  border-bottom: 1px solid #e2e8f0 !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
}
.user-modal-filter-wrap {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
}
.user-filter-btn {
  height: 28px !important;
  padding: 0 10px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  border-radius: 6px !important;
  border: 1px solid #cbd5e1 !important;
  background: #ffffff !important;
  color: #475569 !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  transition: all 0.15s ease !important;
}
.user-filter-btn.active {
  background: #2563eb !important;
  color: #ffffff !important;
  border-color: #1d4ed8 !important;
}
.btn-filter-pending.active {
  background: #ea580c !important;
  border-color: #c2410c !important;
}
.user-search-input {
  height: 28px !important;
  padding: 0 8px !important;
  font-size: 12px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 6px !important;
  width: 160px !important;
  outline: none !important;
}
.user-reload-btn {
  height: 28px !important;
  padding: 0 10px !important;
  font-size: 11.5px !important;
  font-weight: 700 !important;
  border-radius: 6px !important;
  border: 1px solid #cbd5e1 !important;
  background: #ffffff !important;
  color: #334155 !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
}
.user-modal-body {
  padding: 0 !important;
  flex: 1 1 auto !important;
  overflow-y: auto !important;
  max-height: calc(90vh - 140px) !important;
}
.user-table-scroll {
  width: 100% !important;
  overflow-x: auto !important;
}
.user-approval-table {
  width: 100% !important;
  border-collapse: collapse !important;
  font-size: 12px !important;
  text-align: left !important;
  min-width: 780px !important;
}
.user-approval-table th {
  background: #f1f5f9 !important;
  color: #334155 !important;
  font-weight: 700 !important;
  padding: 8px 10px !important;
  border-bottom: 2px solid #cbd5e1 !important;
  white-space: nowrap !important;
  position: sticky !important;
  top: 0 !important;
  z-index: 10 !important;
}
.user-approval-table td {
  padding: 6px 10px !important;
  border-bottom: 1px solid #e2e8f0 !important;
  vertical-align: middle !important;
  color: #0f172a !important;
}
.user-approval-table tr:hover td {
  background: #f8fafc !important;
}
.user-row-pending td {
  background: #fffbeb !important;
}
.user-edit-input {
  width: 100% !important;
  box-sizing: border-box !important;
  height: 26px !important;
  padding: 0 6px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 4px !important;
  outline: none !important;
  background: #ffffff !important;
}
.user-edit-input:focus {
  border-color: #2563eb !important;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15) !important;
}
.user-edit-select {
  height: 26px !important;
  padding: 0 4px !important;
  font-size: 11.5px !important;
  font-weight: 600 !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 4px !important;
  background: #ffffff !important;
  cursor: pointer !important;
  outline: none !important;
  width: 100% !important;
}
.user-btn-save {
  height: 25px !important;
  padding: 0 8px !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  border-radius: 4px !important;
  border: 1px solid #1d4ed8 !important;
  background: #2563eb !important;
  color: #ffffff !important;
  cursor: pointer !important;
  white-space: nowrap !important;
}
.user-btn-save:hover {
  background: #1d4ed8 !important;
}
.user-btn-quick-appr {
  height: 25px !important;
  padding: 0 8px !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  border-radius: 4px !important;
  border: 1px solid #16a34a !important;
  background: #22c55e !important;
  color: #ffffff !important;
  cursor: pointer !important;
  white-space: nowrap !important;
}
.user-btn-quick-appr:hover {
  background: #16a34a !important;
}
.user-btn-del {
  height: 25px !important;
  padding: 0 6px !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  border-radius: 4px !important;
  border: 1px solid #ef4444 !important;
  background: #ffffff !important;
  color: #dc2626 !important;
  cursor: pointer !important;
  white-space: nowrap !important;
}
.user-btn-del:hover {
  background: #fee2e2 !important;
}
.user-modal-footer {
  padding: 10px 16px !important;
  background: #f8fafc !important;
  border-top: 1px solid #e2e8f0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 10px !important;
}
.user-footer-note {
  font-size: 11.5px !important;
  color: #64748b !important;
}
.user-modal-btn-close {
  height: 28px !important;
  padding: 0 14px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  border-radius: 6px !important;
  border: 1px solid #cbd5e1 !important;
  background: #ffffff !important;
  color: #334155 !important;
  cursor: pointer !important;
}
