/*
Theme Name: Classic Burgundy Blog
Theme URI: https://bullionpro.velagold.kr
Description: 네이버/티스토리 블로그 스타일의 클래식 버건디 테마 - 금거래소 허가 절차 전문 블로그
Author: 한국 공식 금 거래소
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GNU General Public License v2 or later
Text Domain: classic-burgundy
*/

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --burgundy: #800020;
  --dark-burgundy: #500014;
  --light-burgundy: #a0325a;
  --gold: #d4af37;
  --light-gold: #f0d060;
  --cream: #fffdf5;
  --warm-gray: #f8f6f3;
  --text-dark: #2c2c2c;
  --text-medium: #555;
  --text-light: #888;
  --border: #e8e4df;
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --shadow-hover: 0 4px 20px rgba(0,0,0,0.12);
  --radius: 8px;
  --max-width: 1100px;
  --sidebar-width: 300px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, 'Malgun Gothic', sans-serif;
  background: var(--warm-gray);
  color: var(--text-dark);
  line-height: 1.8;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--burgundy); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--gold); }

img { max-width: 100%; height: auto; display: block; }

/* ===== HEADER ===== */
.site-header {
  background: linear-gradient(135deg, var(--dark-burgundy), var(--burgundy));
  color: white;
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
}

.site-logo img {
  height: 48px;
  width: auto;
}

.site-title {
  font-size: 22px;
  font-weight: 700;
  color: white;
  letter-spacing: -0.5px;
}

.site-title span { color: var(--gold); }

.header-contact {
  font-size: 13px;
  color: rgba(255,255,255,0.8);
}

.header-contact a { color: var(--gold); font-weight: 600; }

/* ===== NAVIGATION ===== */
.site-nav {
  background: var(--dark-burgundy);
  border-top: 1px solid rgba(255,255,255,0.1);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.site-nav ul {
  list-style: none;
  display: flex;
  gap: 0;
}

.site-nav li a {
  display: block;
  padding: 12px 20px;
  color: rgba(255,255,255,0.85);
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
  border-bottom: 3px solid transparent;
}

.site-nav li a:hover,
.site-nav li.current a {
  color: var(--gold);
  background: rgba(255,255,255,0.05);
  border-bottom-color: var(--gold);
}

/* ===== MAIN LAYOUT ===== */
.site-content {
  max-width: var(--max-width);
  margin: 24px auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 1fr var(--sidebar-width);
  gap: 24px;
}

.site-content.full-width {
  grid-template-columns: 1fr;
}

/* ===== BLOG CARDS ===== */
.post-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.post-card {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: box-shadow 0.3s, transform 0.2s;
  display: flex;
}

.post-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.post-card .thumb {
  width: 240px;
  min-height: 180px;
  flex-shrink: 0;
  overflow: hidden;
}

.post-card .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.post-card:hover .thumb img { transform: scale(1.05); }

.post-card .card-body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.post-card .category {
  display: inline-block;
  background: var(--cream);
  color: var(--burgundy);
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 12px;
  border: 1px solid var(--border);
  margin-bottom: 8px;
  width: fit-content;
}

.post-card .card-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 8px;
  color: var(--text-dark);
}

.post-card .card-title a { color: inherit; }
.post-card .card-title a:hover { color: var(--burgundy); }

.post-card .card-excerpt {
  font-size: 14px;
  color: var(--text-medium);
  line-height: 1.7;
  flex: 1;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.post-card .card-meta {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-light);
  display: flex;
  gap: 16px;
}

/* ===== SIDEBAR ===== */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.sidebar-widget {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.widget-title {
  background: var(--burgundy);
  color: white;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.widget-body { padding: 16px; }

.widget-body ul { list-style: none; }

.widget-body li {
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

.widget-body li:last-child { border-bottom: none; }

.widget-body li a {
  color: var(--text-dark);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.widget-body li a:hover { color: var(--burgundy); }

.widget-body li .count {
  background: var(--cream);
  color: var(--burgundy);
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 600;
}

/* Profile widget */
.profile-widget {
  text-align: center;
  padding: 24px 16px;
}

.profile-widget .profile-img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--gold);
  margin: 0 auto 12px;
}

.profile-widget .profile-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--burgundy);
}

.profile-widget .profile-desc {
  font-size: 13px;
  color: var(--text-medium);
  margin-top: 6px;
  line-height: 1.6;
}

.profile-widget .profile-contact {
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-dark);
  font-weight: 600;
}

/* ===== SINGLE POST ===== */
.single-post-wrap {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.single-post-header {
  background: linear-gradient(135deg, var(--dark-burgundy), var(--burgundy));
  color: white;
  padding: 40px 36px 32px;
}

.single-post-header .post-category {
  display: inline-block;
  background: rgba(212,175,55,0.2);
  color: var(--gold);
  font-size: 13px;
  font-weight: 600;
  padding: 4px 14px;
  border-radius: 14px;
  border: 1px solid rgba(212,175,55,0.3);
  margin-bottom: 12px;
}

.single-post-header h1 {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.4;
  margin-bottom: 16px;
}

.single-post-header .post-meta {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
  display: flex;
  gap: 20px;
}

.single-featured-image {
  width: 100%;
  max-height: 450px;
  object-fit: cover;
}

.single-post-content {
  padding: 36px;
  font-size: 16px;
  line-height: 1.9;
}

.single-post-content h2 {
  font-size: 22px;
  font-weight: 700;
  color: var(--burgundy);
  margin: 36px 0 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--gold);
}

.single-post-content h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--dark-burgundy);
  margin: 28px 0 12px;
}

.single-post-content p { margin-bottom: 18px; }

.single-post-content ul, .single-post-content ol {
  margin: 12px 0 18px 24px;
}

.single-post-content li { margin-bottom: 8px; }

.single-post-content blockquote {
  border-left: 4px solid var(--gold);
  background: var(--cream);
  padding: 16px 20px;
  margin: 20px 0;
  font-style: italic;
  color: var(--text-medium);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.single-post-content .info-box {
  background: linear-gradient(135deg, #fdf8e8, #fff8dc);
  border: 1px solid var(--gold);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 24px 0;
}

.single-post-content .info-box h4 {
  color: var(--burgundy);
  font-size: 16px;
  margin-bottom: 10px;
}

.single-post-content .step-box {
  background: white;
  border: 1px solid var(--border);
  border-left: 4px solid var(--burgundy);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 16px 20px;
  margin: 16px 0;
}

.single-post-content .step-box .step-num {
  display: inline-block;
  background: var(--burgundy);
  color: white;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  text-align: center;
  line-height: 28px;
  font-size: 14px;
  font-weight: 700;
  margin-right: 10px;
}

.single-post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 14px;
}

.single-post-content table th {
  background: var(--burgundy);
  color: white;
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
}

.single-post-content table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
}

.single-post-content table tr:nth-child(even) td {
  background: var(--cream);
}

/* FAQ Section */
.faq-section { margin: 32px 0; }

.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  background: var(--cream);
  cursor: pointer;
  font-weight: 600;
  color: var(--burgundy);
  transition: background 0.2s;
}

.faq-question:hover { background: #f5f0e5; }

.faq-question::after {
  content: '+';
  font-size: 20px;
  font-weight: 700;
  color: var(--gold);
  transition: transform 0.3s;
}

.faq-item.active .faq-question::after {
  transform: rotate(45deg);
}

.faq-answer {
  padding: 0 20px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s, padding 0.3s;
  line-height: 1.8;
  color: var(--text-medium);
}

.faq-item.active .faq-answer {
  padding: 16px 20px;
  max-height: 500px;
}

/* CTA Box */
.cta-box {
  background: linear-gradient(135deg, var(--dark-burgundy), var(--burgundy));
  color: white;
  padding: 32px;
  border-radius: var(--radius);
  text-align: center;
  margin: 32px 0;
}

.cta-box h3 {
  color: var(--gold);
  font-size: 22px;
  margin-bottom: 12px;
}

.cta-box p { color: rgba(255,255,255,0.85); margin-bottom: 16px; }

.cta-box .cta-phone {
  display: inline-block;
  background: var(--gold);
  color: var(--dark-burgundy);
  padding: 12px 32px;
  border-radius: 30px;
  font-size: 18px;
  font-weight: 700;
  transition: transform 0.2s, box-shadow 0.2s;
}

.cta-box .cta-phone:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(212,175,55,0.4);
  color: var(--dark-burgundy);
}

/* ===== FOOTER ===== */
.site-footer {
  background: var(--dark-burgundy);
  color: rgba(255,255,255,0.7);
  padding: 40px 20px;
  margin-top: 40px;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 32px;
}

.footer-section h4 {
  color: var(--gold);
  font-size: 15px;
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-section p, .footer-section li {
  font-size: 13px;
  line-height: 1.8;
}

.footer-section ul { list-style: none; }

.footer-section a { color: rgba(255,255,255,0.7); }
.footer-section a:hover { color: var(--gold); }

.footer-bottom {
  max-width: var(--max-width);
  margin: 24px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 12px;
  text-align: center;
}

/* ===== HOMEPAGE HERO ===== */
.hero-section {
  background: linear-gradient(135deg, var(--dark-burgundy) 0%, var(--burgundy) 60%, var(--light-burgundy) 100%);
  color: white;
  padding: 60px 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="40" fill="none" stroke="rgba(212,175,55,0.08)" stroke-width="0.5"/></svg>') repeat;
  background-size: 120px;
}

.hero-content { position: relative; z-index: 1; max-width: 800px; margin: 0 auto; }

.hero-section h1 {
  font-size: 38px;
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.3;
}

.hero-section h1 .gold { color: var(--gold); }

.hero-section .hero-desc {
  font-size: 17px;
  color: rgba(255,255,255,0.85);
  margin-bottom: 28px;
  line-height: 1.7;
}

.hero-section .hero-cta {
  display: inline-block;
  background: var(--gold);
  color: var(--dark-burgundy);
  padding: 14px 40px;
  border-radius: 30px;
  font-size: 17px;
  font-weight: 700;
  transition: all 0.3s;
}

.hero-section .hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212,175,55,0.4);
  color: var(--dark-burgundy);
}

/* Gallery Section */
.gallery-section {
  max-width: var(--max-width);
  margin: 32px auto;
  padding: 0 20px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.gallery-grid img {
  border-radius: var(--radius);
  aspect-ratio: 1;
  object-fit: cover;
  box-shadow: var(--shadow);
  transition: transform 0.3s;
}

.gallery-grid img:hover { transform: scale(1.03); }

.section-title {
  text-align: center;
  font-size: 26px;
  font-weight: 800;
  color: var(--burgundy);
  margin-bottom: 8px;
}

.section-subtitle {
  text-align: center;
  font-size: 15px;
  color: var(--text-light);
  margin-bottom: 28px;
}

/* ===== BREADCRUMB ===== */
.breadcrumb {
  max-width: var(--max-width);
  margin: 16px auto 0;
  padding: 0 20px;
  font-size: 13px;
  color: var(--text-light);
}

.breadcrumb a { color: var(--text-medium); }

/* ===== PAGINATION ===== */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 32px 0;
}

.pagination a, .pagination span {
  display: inline-block;
  padding: 8px 14px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  border: 1px solid var(--border);
  color: var(--text-medium);
  background: white;
}

.pagination .current {
  background: var(--burgundy);
  color: white;
  border-color: var(--burgundy);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .site-content {
    grid-template-columns: 1fr;
  }
  .post-card { flex-direction: column; }
  .post-card .thumb { width: 100%; min-height: 200px; }
  .hero-section h1 { font-size: 26px; }
  .footer-inner { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .single-post-header { padding: 24px 20px; }
  .single-post-header h1 { font-size: 22px; }
  .single-post-content { padding: 20px; }
  .header-contact { display: none; }
  .site-nav ul { overflow-x: auto; }
}

@media (max-width: 480px) {
  .hero-section { padding: 40px 16px; }
  .hero-section h1 { font-size: 22px; }
  .gallery-grid { grid-template-columns: 1fr 1fr; }
}
