/* 고급스러운 다크 테마 스타일 */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #0f0f1e 0%, #1a1a2e 50%, #16213e 100%);
  color: #ffffff;
  min-height: 100vh;
}

/* 스크롤바 스타일 */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: #1a1a2e;
}

::-webkit-scrollbar-thumb {
  background: #e94560;
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: #ff5577;
}

/* 카드 호버 효과 */
.card-hover {
  transition: all 0.3s ease;
}

.card-hover:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(233, 69, 96, 0.3);
}

/* 그라데이션 버튼 */
.gradient-btn {
  background: linear-gradient(135deg, #e94560 0%, #ff6b88 100%);
  transition: all 0.3s ease;
}

.gradient-btn:hover {
  background: linear-gradient(135deg, #ff5577 0%, #ff7799 100%);
  box-shadow: 0 5px 15px rgba(233, 69, 96, 0.5);
}

/* 입력 필드 포커스 효과 */
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: #e94560 !important;
  box-shadow: 0 0 0 3px rgba(233, 69, 96, 0.2);
}

/* 애니메이션 */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.5s ease;
}

/* 프로즈 스타일 (콘텐츠 표시용) */
.prose {
  max-width: 65ch;
}

.prose img {
  border-radius: 0.5rem;
  margin: 1rem 0;
}

.prose h1, .prose h2, .prose h3 {
  margin-top: 1.5rem;
  margin-bottom: 1rem;
  font-weight: bold;
}

.prose p {
  margin-bottom: 1rem;
  line-height: 1.7;
}

.prose a {
  color: #60a5fa;
  text-decoration: underline;
}

.prose a:hover {
  color: #93c5fd;
}

/* 대화 상자 스타일 (이야기용) */
.dialogue-box {
  background: rgba(255, 255, 255, 0.05);
  border-left: 4px solid #e94560;
  padding: 1rem;
  margin: 1rem 0;
  border-radius: 0.5rem;
}

.narration-box {
  background: rgba(79, 70, 229, 0.1);
  border-left: 4px solid #6366f1;
  padding: 1rem;
  margin: 1rem 0;
  border-radius: 0.5rem;
  font-style: italic;
}

/* 워터마크 오버레이 */
.watermark-overlay {
  position: relative;
  overflow: hidden;
}

.watermark-overlay::after {
  content: 'PREVIEW';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  font-weight: bold;
  color: rgba(255, 255, 255, 0.3);
  transform: rotate(-45deg);
  pointer-events: none;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

/* 라이트박스 */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.95);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
}

/* 모바일 최적화 */
@media (max-width: 768px) {
  .main-header nav {
    display: none;
  }

  .mobile-menu-card {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
}

/* 태그 스타일 */
.tag {
  display: inline-block;
  background: rgba(233, 69, 96, 0.2);
  color: #ff6b88;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  margin: 0.25rem;
  cursor: pointer;
  transition: all 0.2s;
}

.tag:hover {
  background: rgba(233, 69, 96, 0.4);
  transform: scale(1.05);
}

/* 로딩 스피너 */
.spinner {
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-left-color: #e94560;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* 배지 */
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem 0.5rem;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-success {
  background: rgba(34, 197, 94, 0.2);
  color: #4ade80;
}

.badge-warning {
  background: rgba(251, 191, 36, 0.2);
  color: #fbbf24;
}

.badge-danger {
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
}

.badge-info {
  background: rgba(59, 130, 246, 0.2);
  color: #60a5fa;
}

/* 페이지네이션 */
.pagination {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  justify-content: center;
  margin-top: 2rem;
}

.pagination button {
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.375rem;
  color: #ffffff;
  cursor: pointer;
  transition: all 0.2s;
}

.pagination button:hover:not(:disabled) {
  background: rgba(233, 69, 96, 0.3);
  border-color: #e94560;
}

.pagination button:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.pagination button.active {
  background: #e94560;
  border-color: #e94560;
  font-weight: bold;
}
