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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f8f9fa;
}

.container {
  max-width: 1000px;
  margin: 0 auto !important;
  padding: 0 20px;
}

/* 헤더 스타일 */
.main-header,
.blog-header,
.post-header {
  color: white;
  padding: 2rem 0;
  margin-bottom: 2rem;
}

.header-content {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.header-main {
  text-align: left;
}

.header-main h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.header-main p {
  font-size: 1.2rem;
  opacity: 0.9;
}

.header-controls {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: flex-end;
}

.language-selector select {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 6px;
  background: white;
  color: #333;
  cursor: pointer;
  font-size: 0.9rem;
}

.admin-login-btn {
  padding: 0.4rem 1rem;
  background: #667eea;
  color: white !important;
  text-decoration: none;
  border-radius: 4px;
  font-size: 0.85rem;
  font-weight: 500;
  transition: all 0.2s;
  white-space: nowrap;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.admin-login-btn:hover {
  background: #5a6fd8;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

/* 랜딩 페이지 스타일 */
.landing-main {
  min-height: 60vh;
  display: flex;
  align-items: center;
}

.hero-section {
  text-align: center !important;
  padding: 4rem 0;
  width: 100% !important;
}

.hero-section .container {
  margin: 0 auto !important;
  text-align: center !important;
  width: 100% !important;
  max-width: 1000px !important;
}

.hero-section h2 {
  font-size: 2.5rem;
  color: #333;
  margin-bottom: 1rem;
  text-align: center !important;
  width: 100% !important;
}

.hero-section p {
  font-size: 1.2rem;
  color: #666;
  margin-bottom: 3rem;
  max-width: 600px;
  margin-left: auto !important;
  margin-right: auto !important;
  text-align: center !important;
  width: auto !important;
}

.cta-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  justify-content: center;
  max-width: 800px;
  margin: 0 auto;
}

.cta-button {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.5rem;
  background: #667eea;
  color: white !important;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.3s;
  border: none;
  text-align: center;
  min-height: 60px;
  font-size: 1rem;
}

.cta-button.primary {
  background: #764ba2;
  color: white !important;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  color: white !important;
}

/* 브레드크럼 */
.breadcrumb {
  background: #e9ecef;
  padding: 1rem 0;
  margin-bottom: 2rem;
}

.breadcrumb a {
  color: #667eea;
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

/* 브레드크럼 + 뉴스레터 통합 */
.breadcrumb-with-newsletter {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 1rem 0;
  margin-bottom: 2rem;
}

.breadcrumb-with-newsletter .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.breadcrumb-left {
  flex: 0 0 auto;
}

.breadcrumb-left a {
  color: white;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
}

.breadcrumb-left a:hover {
  text-decoration: underline;
}

.breadcrumb-newsletter-form {
  flex: 1 1 auto;
  display: flex;
  gap: 0.5rem;
  align-items: center;
  justify-content: flex-end;
  max-width: 500px;
}

.breadcrumb-newsletter-form input[type="email"] {
  flex: 1 1 auto;
  padding: 0.5rem 1rem;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  font-size: 0.9rem;
  background: rgba(255, 255, 255, 0.9);
  min-width: 200px;
}

.breadcrumb-newsletter-form input[type="email"]:focus {
  outline: none;
  border-color: white;
  background: white;
}

.breadcrumb-newsletter-form button {
  flex: 0 0 auto;
  padding: 0.5rem 1.5rem;
  background: white;
  color: #667eea;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.breadcrumb-newsletter-form button:hover {
  background: #f8f9fa;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.newsletter-message-inline {
  flex: 0 0 100%;
  margin-top: 0.5rem;
  padding: 0.5rem;
  border-radius: 4px;
  font-size: 0.85rem;
  display: none;
}

.newsletter-message-inline.success {
  background: rgba(40, 167, 69, 0.9);
  color: white;
}

.newsletter-message-inline.error {
  background: rgba(220, 53, 69, 0.9);
  color: white;
}

/* 반응형 디자인 */
@media (max-width: 768px) {
  .breadcrumb-with-newsletter .container {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
  }

  .breadcrumb-left {
    text-align: center;
  }

  .breadcrumb-newsletter-form {
    max-width: 100%;
    flex-direction: column;
  }

  .breadcrumb-newsletter-form input[type="email"],
  .breadcrumb-newsletter-form button {
    width: 100%;
  }
}

/* 포스트 카드 */
.posts-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.post-card {
  background: white;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s, box-shadow 0.3s;
}

.post-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.post-card h2 {
  margin-bottom: 1rem;
}

.post-card h2 a {
  color: #333;
  text-decoration: none;
  font-size: 1.5rem;
}

.post-card h2 a:hover {
  color: #667eea;
}

.post-meta {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.post-meta span {
  padding: 0.25rem 0.75rem;
  background: #e9ecef;
  border-radius: 20px;
  font-size: 0.875rem;
  color: #495057;
}

.post-excerpt {
  color: #666;
  margin-bottom: 1rem;
  line-height: 1.7;
}

.read-more {
  display: inline-block;
  color: #667eea;
  text-decoration: none;
  font-weight: 600;
}

.read-more:hover {
  text-decoration: underline;
}

/* 포스트 콘텐츠 페이지 */
.post-content {
  background: white;
  padding: 3rem;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  margin-bottom: 2rem;
}

.post-title-section h1 {
  font-size: 2.5rem;
  color: #333;
  margin-bottom: 1.5rem;
  line-height: 1.3;
}

.post-meta-enhanced {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #667eea;
}

.meta-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.meta-label {
  font-weight: 600;
  color: #495057;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.meta-value {
  font-size: 1rem;
  color: #333;
  font-weight: 500;
}

.post-body {
  font-size: 1.1rem;
  line-height: 1.8;
  color: #333;
}

.post-body h1,
.post-body h2,
.post-body h3,
.post-body h4,
.post-body h5,
.post-body h6 {
  margin: 2rem 0 1rem 0;
  color: #333;
}

.post-body p {
  margin-bottom: 1.5rem;
}

.post-body ul,
.post-body ol {
  margin-bottom: 1.5rem;
  padding-left: 2rem;
}

.post-body li {
  margin-bottom: 0.5rem;
}

.post-body blockquote {
  border-left: 4px solid #667eea;
  padding-left: 1.5rem;
  margin: 2rem 0;
  font-style: italic;
  color: #555;
}

.post-body code {
  background: #f8f9fa;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-family: 'Monaco', 'Menlo', monospace;
  font-size: 0.9rem;
}

.post-body pre {
  background: #f8f9fa;
  padding: 1.5rem;
  border-radius: 8px;
  overflow-x: auto;
  margin: 1.5rem 0;
}

.post-body pre code {
  background: none;
  padding: 0;
}

.post-navigation {
  display: flex;
  justify-content: center;
  margin: 2rem 0;
}

.back-to-list {
  display: inline-block;
  padding: 1rem 2rem;
  background: #667eea !important;
  color: white !important;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.3s;
}

.back-to-list:hover {
  background: #5a67d8 !important;
  color: white !important;
  transform: translateY(-2px);
}

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

.pagination a {
  padding: 0.75rem 1.5rem;
  background: #667eea !important;
  color: white !important;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.3s;
}

.pagination a:hover {
  background: #5a67d8 !important;
  color: white !important;
}

.page-info {
  font-weight: 600;
  color: #495057;
}

/* 댓글 시스템 */
.comments-container {
  background: #f5f5f5;
  padding: 2rem;
  border-radius: 12px;
  margin: 3rem 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Other Posts Section */
.other-posts-container {
  background: #e8f5e9;
  padding: 2rem;
  border-radius: 12px;
  margin: 3rem 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.other-posts-list {
  display: grid;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.other-post-item {
  background: white;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  transition: all 0.3s ease;
  border-left: 4px solid #667eea;
  margin-bottom: 0.75rem;
}

.other-post-item:hover {
  background: #f9f9f9;
  transform: translateX(5px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.other-post-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-decoration: none;
  color: inherit;
  gap: 1.5rem;
}

.post-title-left {
  flex: 0 0 auto;
  font-size: 1.1rem;
  font-weight: 600;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 50%;
}

.post-info-right {
  flex: 1 1 auto;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 1rem;
  text-align: right;
}

.post-excerpt {
  font-size: 0.9rem;
  color: #666;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 300px;
}

.post-date {
  font-size: 0.85rem;
  color: #999;
  white-space: nowrap;
  flex-shrink: 0;
}

.pagination-container {
  display: flex;
  justify-content: center;
  padding: 1rem 0;
}

.pagination-buttons {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.page-btn {
  background: white;
  border: 1px solid #ddd;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
  color: #333;
}

.page-btn:hover {
  background: #f0f0f0;
  border-color: #667eea;
}

.page-btn.active {
  background: #667eea;
  color: white;
  border-color: #667eea;
  font-weight: 600;
}

.no-posts, .error {
  text-align: center;
  padding: 2rem;
  color: #666;
  font-size: 1rem;
}

/* Newsletter Section */
.newsletter-section {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 2rem 0;
  margin-bottom: 2rem;
}

.newsletter-box {
  background: white;
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
}

.newsletter-box h3 {
  font-size: 1.3rem;
  margin: 0 0 0.5rem 0;
  color: #333;
}

.newsletter-box p {
  font-size: 0.9rem;
  color: #666;
  margin: 0 0 1rem 0;
}

.newsletter-form {
  display: flex;
  gap: 0.5rem;
  max-width: 500px;
  margin: 0 auto;
}

.newsletter-form input {
  flex: 1;
  padding: 0.6rem 1rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.95rem;
}

.newsletter-form button {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  padding: 0.6rem 1.5rem;
  border-radius: 4px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.newsletter-form button:hover {
  opacity: 0.9;
}

.newsletter-message {
  margin-top: 0.8rem;
  padding: 0.6rem;
  border-radius: 4px;
  font-size: 0.9rem;
  display: none;
}

.newsletter-message.success {
  background: #d4edda;
  color: #155724;
}

.newsletter-message.error {
  background: #f8d7da;
  color: #721c24;
}

/* Comments */
.comment-form {
  margin-bottom: 2rem;
}

.comment-form h3 {
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
  color: #495057;
}

.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: #495057;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.btn-submit {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  padding: 0.5rem 1.5rem;
  border-radius: 4px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.3s;
}

.btn-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(102, 126, 234, 0.3);
}

.message {
  display: none;
  padding: 1rem;
  border-radius: 6px;
  margin-top: 1rem;
  font-weight: 500;
}

.message.success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.message.error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.comments-list h3 {
  font-size: 1.3rem;
  margin-bottom: 1.5rem;
  color: #495057;
}

.comment-item {
  padding: 1.5rem;
  background: #f8f9fa;
  border-radius: 8px;
  margin-bottom: 1rem;
  border-left: 4px solid #667eea;
}

.comment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.comment-header strong {
  color: #333;
  font-size: 1.1rem;
}

.comment-date {
  color: #6c757d;
  font-size: 0.9rem;
}

.comment-content {
  color: #495057;
  line-height: 1.6;
  word-wrap: break-word;
}

.no-comments {
  text-align: center;
  color: #6c757d;
  font-style: italic;
  padding: 2rem;
}

/* 시리즈 네비게이션 컨테이너 */
.series-navigation-container {
  background: #e8f5e9;
  padding: 2rem;
  border-radius: 12px;
  margin: 3rem 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.section-title {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: #333;
}

.section-divider {
  border: none;
  border-top: 2px solid rgba(0, 0, 0, 0.1);
  margin: 1.5rem 0;
}

.series-info {
  text-align: center;
  margin-bottom: 2rem;
}

.series-badge {
  font-size: 1.5rem;
  color: #667eea;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.series-description {
  color: #6c757d;
  font-size: 1rem;
}

.series-nav-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.series-nav-prev,
.series-nav-next {
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  background: white;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.3s;
  border: 2px solid transparent;
}

.series-nav-prev:hover,
.series-nav-next:hover {
  border-color: #667eea;
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
}

.series-nav-prev {
  text-align: left;
}

.series-nav-next {
  text-align: right;
}

.nav-label {
  display: block;
  font-size: 0.9rem;
  color: #667eea;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.nav-title {
  display: block;
  font-size: 1.1rem;
  color: #333;
  font-weight: 500;
}

.series-posts-header {
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid #667eea;
}

.series-posts-header h4 {
  color: #333;
  font-size: 1.3rem;
  margin: 0;
}

.series-posts {
  list-style: none;
  padding: 0;
  margin: 0;
}

.series-posts li {
  padding: 1rem;
  margin-bottom: 0.75rem;
  background: white;
  border-radius: 8px;
  border-left: 4px solid #dee2e6;
  transition: all 0.3s;
}

.series-posts li:hover {
  border-left-color: #667eea;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.series-posts li.current-post {
  background: #667eea;
  border-left-color: #764ba2;
}

.series-posts li.current-post .post-title {
  color: white;
  font-weight: 600;
}

.series-posts li.current-post .post-number {
  color: rgba(255, 255, 255, 0.9);
}

.series-posts li a {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: inherit;
}

.series-posts .post-number {
  font-weight: 600;
  color: #667eea;
  margin-right: 0.75rem;
  min-width: 2rem;
}

.series-posts .post-title {
  flex: 1;
  color: #333;
  font-size: 1rem;
}

.current-badge {
  color: white;
  font-size: 0.85rem;
  font-weight: 500;
  margin-left: 0.75rem;
}

@media (max-width: 768px) {
  .series-nav-grid {
    grid-template-columns: 1fr;
  }

  .series-nav-next {
    text-align: left;
  }

  .series-posts li {
    padding: 0.75rem;
  }

  .series-posts .post-title {
    font-size: 0.95rem;
  }
}

/* 뉴스레터 섹션 */
.newsletter-section {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 4rem 0;
  margin-top: 4rem;
}

.newsletter-box {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
  color: white;
}

.newsletter-box h3 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: white;
}

.newsletter-box p {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  opacity: 0.9;
}

.newsletter-form {
  display: flex;
  gap: 1rem;
  max-width: 500px;
  margin: 0 auto;
}

.newsletter-form input[type="email"] {
  flex: 1;
  padding: 1rem;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
}

.newsletter-form button {
  padding: 1rem 2rem;
  background: white;
  color: #667eea;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.newsletter-form button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.newsletter-form button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.newsletter-message {
  margin-top: 1rem;
  padding: 1rem;
  border-radius: 6px;
  font-size: 0.95rem;
}

.newsletter-message .success {
  background: rgba(76, 175, 80, 0.2);
  border: 1px solid rgba(76, 175, 80, 0.5);
  color: white;
  padding: 1rem;
  border-radius: 6px;
}

.newsletter-message .error {
  background: rgba(244, 67, 54, 0.2);
  border: 1px solid rgba(244, 67, 54, 0.5);
  color: white;
  padding: 1rem;
  border-radius: 6px;
}

/* 푸터 */
footer {
  background: #343a40;
  color: white;
  text-align: center;
  padding: 2rem 0;
  margin-top: 0;
}

/* 반응형 디자인 */
@media (max-width: 768px) {
  .container {
    padding: 0 15px;
  }

  .header-content {
    flex-direction: column;
    text-align: center;
    gap: 1.5rem;
  }

  .header-controls {
    position: static;
    flex-direction: column;
    align-items: center;
    margin-top: 1rem;
    gap: 0.8rem;
  }

  .admin-login-inline form {
    justify-content: center;
  }

  .header-main h1 {
    font-size: 2rem;
  }

  .header-main p {
    font-size: 1rem;
  }

  .header-controls {
    justify-content: center;
  }

  .hero-section h2 {
    font-size: 2rem;
  }

  .hero-section p {
    font-size: 1rem;
  }

  .cta-buttons {
    grid-template-columns: 1fr;
    max-width: 300px;
  }

  .cta-button {
    width: 100%;
    min-height: 60px;
  }

  .post-content {
    padding: 2rem 1.5rem;
  }

  .post-title-section h1 {
    font-size: 2rem;
  }

  .post-meta-enhanced {
    grid-template-columns: 1fr;
    padding: 1rem;
  }

  .post-meta {
    flex-direction: column;
    gap: 0.5rem;
  }

  .pagination {
    flex-direction: column;
    gap: 0.5rem;
  }

  .newsletter-form {
    flex-direction: column;
  }

  .newsletter-box h3 {
    font-size: 1.5rem;
  }

  .newsletter-box p {
    font-size: 1rem;
  }
}
