body { font-family: 'Pretendard', sans-serif; background-color: #f8fafc; color: #0f172a; overflow-x: hidden; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }

.step-hidden, .modal-hidden { display: none !important; }
.hidden-view { display: none !important; }
.glass-panel { background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(12px); border-bottom: 1px solid #e2e8f0; z-index: 50; }
.modern-card { background: white; border-radius: 16px; box-shadow: 0 4px 20px -2px rgba(0,0,0,0.03); border: 1px solid #edf2f7; transition: all 0.3s ease; }

/* 메인 토글 스위치 */
.mode-toggle { position: relative; background: #e2e8f0; border-radius: 9999px; padding: 4px; display: inline-flex; align-items: center; cursor: pointer; transition: background 0.3s; }
.mode-toggle input { display: none; }
.toggle-btn { position: relative; z-index: 10; padding: 6px 20px; font-size: 0.875rem; font-weight: 700; border-radius: 9999px; transition: color 0.3s; color: #64748b; }
.toggle-btn.active { color: #ffffff; }
.toggle-slider { position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc(50% - 4px); background: #4f46e5; border-radius: 9999px; transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1); box-shadow: 0 2px 10px rgba(79, 70, 229, 0.3); }
input:checked + .toggle-slider { transform: translateX(100%); }

/* 폼 & 입력 */
.form-input { width: 100%; padding: 0.75rem 1rem; border: 1px solid #e2e8f0; border-radius: 0.75rem; background-color: #ffffff; transition: all 0.2s; font-size: 0.875rem; outline: none; }
.form-input:focus { border-color: #6366f1; box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15); }
.editable-title { background: transparent; border: 2px solid transparent; border-radius: 8px; text-align: center; outline: none; transition: all 0.3s; }
.editable-title:focus { background: white; border-color: #6366f1; box-shadow: 0 4px 12px rgba(0,0,0,0.05); }
.form-select { appearance: none; background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e"); background-position: right 0.75rem center; background-repeat: no-repeat; background-size: 1.25em 1.25em; padding-right: 2.5rem; }

/* 다국어 탭 및 커스텀 체크박스 (Quick Doc) */
.custom-checkbox { display: inline-flex; align-items: center; cursor: pointer; }
.custom-checkbox input { display: none; }
.checkmark { width: 20px; height: 20px; border: 2px solid #cbd5e1; border-radius: 6px; margin-right: 8px; display: flex; align-items: center; justify-content: center; background: white; }
.custom-checkbox input:checked + .checkmark { background: #0d9488; border-color: #0d9488; }
.custom-checkbox input:checked + .checkmark::after { content: ''; width: 5px; height: 10px; border: solid white; border-width: 0 2px 2px 0; transform: rotate(45deg); margin-bottom: 2px; }

.lang-tab { padding: 10px 24px; font-size: 0.875rem; font-weight: 700; color: #64748b; cursor: pointer; border-radius: 8px 8px 0 0; border: 1px solid transparent; border-bottom: none; margin-bottom: -1px; }
.lang-tab.active { color: #0d9488; background: white; border-color: #e2e8f0; }

/* 관리자 사이드바 탭 */
.admin-tab { width: 100%; text-align: left; padding: 10px 16px; border-radius: 8px; font-weight: 600; font-size: 0.875rem; color: #64748b; transition: all 0.2s; margin-bottom: 4px; cursor: pointer; border: 1px solid transparent; }
.admin-tab.active { background: #eef2ff; color: #4f46e5; border-color: #e0e7ff; }
.data-table th { background-color: #f8fafc; color: #475569; font-weight: 700; font-size: 0.75rem; padding: 12px 16px; border-bottom: 1px solid #e2e8f0; }
.data-table td { padding: 16px; border-bottom: 1px solid #f1f5f9; color: #334155; font-size: 0.875rem; }

/* 마크다운 & TOC */
.fade-in { animation: fadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.markdown-body h3 { font-size: 1.15rem; font-weight: 800; margin-bottom: 1rem; color: #0f172a; border-bottom: 2px solid #f1f5f9; padding-bottom: 0.5rem; }
.markdown-body p { margin-bottom: 1rem; line-height: 1.6; color: #475569; font-size: 0.95rem; }
.markdown-body table { width: 100%; border-collapse: collapse; margin: 1.5em 0; font-size: 0.875rem; border-radius: 8px; overflow: hidden; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
.markdown-body th, .markdown-body td { border: 1px solid #e2e8f0; padding: 12px; }
.markdown-body th { background: #f1f5f9; font-weight: 600; text-align: left; }
.toc-table th { background: #f8fafc; color: #334155; font-weight: 700; font-size: 0.85rem; padding: 12px; }
.toc-table td { border-bottom: 1px solid #f1f5f9; }
.toc-table input, .toc-table select { width: 100%; border: 1px solid transparent; padding: 8px 6px; border-radius: 6px; outline: none; background: transparent; }
.toc-table input:focus, .toc-table select:focus { border: 1px solid #818cf8; background: #fff; box-shadow: 0 0 0 3px rgba(129, 140, 248, 0.15); }
