:root {
  --bg: #fafaf7;
  --fg: #1a1a1a;
  --muted: #6b6b6b;
  --line: #e5e5e0;
  --accent: #ff5a5a;
  --gold: #c8a85a;
  --card: #ffffff;
  --shadow: 0 2px 14px rgba(0,0,0,.06);
  --r: 12px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font: 15px/1.55 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Segoe UI", sans-serif;
  background: var(--bg); color: var(--fg);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; }
.muted { color: var(--muted); }
.small { font-size: 12px; }

.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }

/* TOP BAR */
.topbar { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.topbar .wrap { display: flex; align-items: center; gap: 24px; height: 60px; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 800; }
.logo-img { height: 36px; width: 36px; object-fit: cover; border-radius: 8px; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.logo-text { font-size: 13px; letter-spacing: 3px; color: var(--fg); font-weight: 700; }
.nav { display: flex; gap: 18px; flex: 1; font-weight: 600; font-size: 14px; }
.nav a { color: var(--muted); padding: 6px 0; border-bottom: 2px solid transparent; }
.nav a.on { color: var(--fg); border-bottom-color: var(--accent); }
/* 햄버거 토글 — 모바일 전용 */
.nav-toggle { display: none; background: none; border: 0; padding: 8px 6px; cursor: pointer; margin-left: auto; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--fg); border-radius: 2px; margin: 4px 0; transition: transform .2s, opacity .2s; }
.nav-toggle.on span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle.on span:nth-child(2) { opacity: 0; }
.nav-toggle.on span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
/* 네이버 버튼 (헤더용) */
.naver-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: #03C75A; color: #fff !important; font-weight: 700; font-size: 13px;
  padding: 8px 14px; border-radius: 8px; transition: background .15s;
}
.naver-btn:hover { background: #02b150; }
.naver-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px; background: #fff; color: #03C75A; border-radius: 4px;
  font-weight: 900; font-size: 12px; font-family: -apple-system, system-ui, sans-serif;
}

/* 언어 스위쳐 + 로그인 버튼 */
.lang-switch { display: flex; gap: 2px; background: #f3f3ee; border-radius: 6px; padding: 2px; }
.lang-switch a { padding: 4px 8px; font-size: 11px; font-weight: 700; color: var(--muted); border-radius: 4px; }
.lang-switch a.on { background: var(--fg); color: #fff; }
.auth-btn { font-size: 12px; color: var(--muted); padding: 6px 10px; border: 1px solid var(--line); border-radius: 6px; }
.auth-btn:hover { background: var(--fg); color: #fff; border-color: var(--fg); }
@media (max-width:760px) { .lang-switch a { padding: 3px 6px; font-size: 10px; } .auth-btn { font-size: 11px; padding: 4px 8px; } }
@media (max-width:640px){ .nav{ font-size:13px; gap:12px; } .topbar .wrap{ gap:10px; } .logo-text{display:none} .naver-btn{padding:6px 10px;font-size:12px}}

.flash { background: #fff7d8; border: 1px solid #f0d97a; padding: 10px 16px; max-width: 1180px; margin: 12px auto; border-radius: 8px; }

/* HERO CAROUSEL */
.hero-carousel { position: relative; height: 360px; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero-slides { position: absolute; inset: 0; }
.hero-slide {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0; transition: opacity 1s ease;
}
.hero-slide.on { opacity: 1; }
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.0) 0%, rgba(255,255,255,0.55) 60%, rgba(255,255,255,0.85) 100%);
  display: flex; align-items: flex-end; padding-bottom: 60px;
}
.hero-overlay h1 { font-size: 44px; margin: 0 0 4px; letter-spacing: -0.5px; color: #2a1820; font-weight: 800; }
.hero-overlay .hero-en { font-size: 13px; letter-spacing: 3px; text-transform: uppercase; color: #7d3a4c; font-weight: 700; margin: 0 0 14px; }
.hero-overlay p { color: #4a3239; margin: 0; font-size: 14px; }
.hero-stats { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 12px !important; }
.hero-stats span { color: #4a3239; font-size: 13px; }
.hero-stats strong { color: #7d3a4c; font-size: 18px; font-weight: 800; margin-right: 4px; }
@media (max-width:640px){ .hero-overlay h1 { font-size: 28px; } .hero-stats span { font-size: 11px; } .hero-stats strong { font-size: 14px; } }

/* 오늘의 픽 */
.featured { padding: 32px 16px 8px; }
.ft-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 14px; }
.ft-head h2 { margin: 0; font-size: 20px; }
.ft-head .more { color: var(--muted); font-size: 13px; }
.ft-head .more:hover { color: var(--accent); }
.ft-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(220px,1fr)); gap: 14px; }
.ft-card { background: linear-gradient(180deg, #fff, #fafaf7); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; transition: all .15s; }
.ft-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,.08); }
.ft-img { aspect-ratio: 1/1; background: #fff; display: flex; align-items: center; justify-content: center; padding: 10px; border-bottom: 1px solid var(--line); }
.ft-img img { max-width: 100%; max-height: 100%; object-fit: contain; }
.ft-meta { padding: 12px 14px; }
.ft-brand { font-size: 10px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; }
.ft-name { font-weight: 700; font-size: 13px; line-height: 1.4; margin: 4px 0 6px; }
.ft-info { font-size: 11px; color: var(--muted); }

/* 카탈로그 컨트롤 */
.catalog-controls { display: flex; align-items: center; gap: 10px; margin-bottom: 20px; flex-wrap: wrap; }
.catalog-controls h2 { margin: 0; font-size: 20px; flex-shrink: 0; }
.cat-search { flex: 1; min-width: 200px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 20px; font-size: 14px; }
.catalog-controls select { padding: 9px 12px; border: 1px solid var(--line); border-radius: 6px; font-size: 13px; }
.view-toggle { display: flex; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.view-toggle a { padding: 8px 12px; color: var(--muted); font-size: 16px; line-height: 1; }
.view-toggle a.on { background: var(--fg); color: #fff; }

/* 카드 연번 */
.card { position: relative; }
.card-num { position: absolute; top: 8px; left: 8px; background: rgba(0,0,0,.6); color: #fff; font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 10px; z-index: 2; }

/* 테이블뷰 */
.catalog-table { width: 100%; border-collapse: collapse; font-size: 13px; background: #fff; border-radius: 10px; overflow: hidden; box-shadow: var(--shadow); }
.catalog-table th, .catalog-table td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); }
.catalog-table th { background: #fafaf7; font-size: 12px; color: var(--muted); font-weight: 600; }
.catalog-table tbody tr { cursor: pointer; transition: background .1s; }
.catalog-table tbody tr:hover { background: #fff8f8; }
.catalog-table tbody tr.sold { opacity: 0.5; }
.catalog-table .num { width: 32px; color: var(--muted); text-align: right; }
.catalog-table .thumb-mini { width: 40px; height: 40px; object-fit: contain; background: #f3f3ee; border-radius: 4px; }
.b-sold { background: #fee2e2; color: #991b1b; padding: 2px 8px; border-radius: 8px; font-size: 11px; font-weight: 600; }
.b-ok { background: #d1fae5; color: #065f46; padding: 2px 8px; border-radius: 8px; font-size: 11px; font-weight: 600; }
.hero-overlay strong { color: var(--accent); font-weight: 700; }
.hero-overlay a:not(.hero-cta) { color: var(--accent); text-decoration: underline; }
.hero-cta {
  display: inline-flex; align-items: center; gap: 8px;
  background: #03C75A; color: #fff !important; font-weight: 700; font-size: 15px;
  padding: 12px 20px; border-radius: 10px; margin-top: 14px;
  text-decoration: none !important; box-shadow: 0 2px 10px rgba(3,199,90,.3);
  transition: transform .15s, box-shadow .15s;
}
.hero-cta:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(3,199,90,.4); }
.hero-dots {
  position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 8px; z-index: 2;
}
.hero-dots .dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: rgba(255,255,255,.6); border: 1px solid rgba(0,0,0,.15);
  padding: 0; transition: background .2s, transform .2s;
}
.hero-dots .dot.on { background: var(--accent); transform: scale(1.25); border-color: var(--accent); }
@media (max-width:640px){
  .hero-carousel { height: 280px; }
  .hero-overlay h1 { font-size: 22px; }
  .hero-overlay { padding-bottom: 44px; }
}

/* CATALOG */
.catalog { padding: 32px 16px 60px; }
.catalog-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 20px; flex-wrap: wrap; gap: 12px; }
.catalog-head h2 { margin: 0; font-size: 20px; }
.sort { display: flex; gap: 4px; }
.sort a { padding: 6px 12px; border-radius: 16px; color: var(--muted); font-size: 13px; }
.sort a.on { background: var(--fg); color: #fff; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; }
.card { background: var(--card); border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow); transition: transform .15s, box-shadow .15s; display: block; }
.card:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(0,0,0,.1); }
.card.is-sold { opacity: .55; }
.thumb { aspect-ratio: 1/1; background: #fff; overflow: hidden; display:flex; align-items:center; justify-content:center; padding:6px; }
.thumb img { max-width: 100%; max-height: 100%; width:auto; height:auto; object-fit: contain; }
.meta { padding: 14px; }
.meta .brand { font-size: 11px; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase; margin-bottom: 4px; }
.meta .name { font-size: 14px; font-weight: 600; color: var(--fg); margin-bottom: 10px; line-height: 1.4; min-height: 39px; }
.meta .price { display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.meta .price .unit { color: var(--accent); font-weight: 700; }
.meta .price .pack { color: var(--muted); font-size: 12px; }
.meta .price small { color: var(--muted); font-weight: 400; font-size: 11px; }
.meta .price-line { display:flex; flex-direction:column; gap:2px; font-size:14px; }
.meta .price-line .p-rand { color: var(--accent); font-weight: 800; }
.meta .price-line small { color: var(--muted); font-weight: 400; font-size: 11px; line-height:1.4; }
.meta .price-line.draft { color: var(--muted); font-style: italic; font-size:12px; }
.meta .brand-row { display:flex; align-items:center; gap:6px; margin-bottom:4px; flex-wrap:wrap; }
.meta .brand { font-size: 11px; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase; }
.meta .maker { font-size: 10px; color: var(--muted); padding: 1px 6px; background:#f3f3ee; border-radius:6px; }
.card.is-draft { opacity: .85; }
.card.is-draft .name::after { content:" · 정리중"; color: var(--muted); font-weight: 400; font-size: 11px; }
.meta .stock { margin-top: 8px; font-size: 11px; color: #4a8c4a; }
.meta .stock.sold { color: #c44; }

/* PRODUCT DETAIL */
.product { padding: 24px 16px 60px; }
.back { color: var(--muted); font-size: 13px; display: inline-block; margin-bottom: 16px; }
.product-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.product-grid .ph { background: #fff; border-radius: var(--r); aspect-ratio: 1/1; overflow: hidden; display:flex; align-items:center; justify-content:center; padding: 8px; border: 1px solid var(--line); }
.product-grid .ph img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.product-grid .info .brand { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; }
.product-grid h1 { margin: 6px 0 8px; font-size: 26px; line-height: 1.3; }
.product-grid .jp { color: var(--muted); font-size: 13px; margin: 0 0 20px; }
@media (max-width:760px){ .product-grid{ grid-template-columns: 1fr; } }

.price-table { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 12px 16px; margin: 16px 0; }
.price-table .row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.price-table .row:last-child { border-bottom: 0; }
.price-table .row.hi .val { color: var(--accent); font-weight: 800; font-size: 18px; }
.price-table .label { color: var(--muted); font-size: 13px; }
.price-table .val { font-weight: 700; font-size: 16px; }
.price-table small { color: var(--muted); font-weight: 400; font-size: 11px; margin-left: 6px; }

.stock-line { padding: 10px 14px; background: #ebf6ea; color: #2c682c; border-radius: 8px; font-size: 13px; font-weight: 600; margin-bottom: 16px; }
.stock-line.sold { background: #fbeaea; color: #a02a2a; }

.buy { display: flex; flex-direction: column; gap: 12px; }
.opt-row { display: flex; gap: 12px; }
.opt-row label { flex: 1; padding: 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-size: 14px; background: #fff; }
.opt-row label:has(input:checked) { border-color: var(--accent); background: #fff6f6; }
.opt-row input { margin-right: 6px; }

.qty-row { display: flex; align-items: center; gap: 0; max-width: 160px; }
.qty-row input { width: 60px; text-align: center; border: 1px solid var(--line); border-left: 0; border-right: 0; padding: 10px 0; font-size: 16px; }
.qty-btn { width: 44px; height: 42px; background: #fff; border: 1px solid var(--line); font-size: 18px; }
.qty-btn:first-child { border-radius: 8px 0 0 8px; }
.qty-btn:last-child { border-radius: 0 8px 8px 0; }

.btn-primary { background: var(--accent); color: #fff; border: 0; padding: 14px 22px; border-radius: 10px; font-weight: 700; font-size: 15px; }
.btn-primary:hover { background: #e54545; }
.btn-primary[disabled] { background: #aaa; cursor: not-allowed; }
.btn-primary.big { width: 100%; padding: 16px; font-size: 16px; }

.note { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.note p { margin: 6px 0; }
.note a { color: var(--accent); text-decoration: underline; }

/* === product v2 === */
.ph-stack { display: flex; flex-direction: column; gap: 10px; }
.thumb-strip { display: flex; gap: 8px; overflow-x: auto; }
.thumb-strip .th { width: 64px; height: 64px; padding: 0; border: 2px solid var(--line); border-radius: 8px; overflow: hidden; background:#fff; flex-shrink:0; cursor:pointer; }
.thumb-strip .th.on { border-color: var(--accent); }
.thumb-strip .th img { width: 100%; height: 100%; object-fit: cover; }

.brand-row { display:flex; align-items:center; gap:8px; margin-bottom:6px; flex-wrap:wrap; font-size:12px; }
.brand-row .brand { font-weight:700; letter-spacing:0.5px; text-transform:uppercase; }
.brand-row .maker, .brand-row .release { color: var(--muted); padding: 2px 8px; background:#f3f3ee; border-radius:8px; font-size:11px; }
.product-grid .info .jp { color: var(--muted); font-size: 13px; margin: 4px 0 2px; }
.product-grid .info .series { color: var(--muted); font-size: 12px; margin: 0 0 16px; }

.info-box { background: #fff7e6; border: 1px solid #f0c674; padding: 14px; border-radius: 8px; color: #6c5418; margin: 16px 0; font-size: 14px; }

.price-table.v2 .row.hi { background: linear-gradient(90deg, #fff5f5, #fff); }
.price-table.v2 .row .label small { color: var(--muted); font-weight: 400; font-size: 11px; margin-left: 4px; }
.price-table.v2 .val { color: var(--accent); font-weight: 800; font-size: 16px; }
.price-table.v2 .row.hi .val { font-size: 18px; }

.stock-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0; }
.ss-item { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 12px 8px; text-align: center; font-size: 11px; color: var(--muted); }
.ss-item strong { display: block; color: var(--fg); font-size: 16px; margin-top: 2px; }

.btn-naver {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: #03C75A; color: #fff; font-weight: 700; font-size: 14px;
  padding: 10px 18px; border-radius: 8px; border: 0; text-decoration: none;
  transition: background .15s;
}
.btn-naver:hover { background: #02b150; color: #fff; }
.btn-naver.big { width: 100%; padding: 18px; font-size: 16px; box-shadow: 0 2px 10px rgba(3,199,90,.25); }
.hint-line { margin: 10px 0 0; text-align: center; }

.story { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); }
.story h2 { font-size: 17px; margin: 0 0 12px; }
.story-body { color: #333; line-height: 1.7; font-size: 14px; }

/* characters */
.characters { margin-top: 48px; }
.characters h2 { font-size: 18px; margin-bottom: 16px; }
.characters.empty { color: var(--muted); }
.char-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }
.char-card { background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.char-card.sold { opacity: .55; }
.char-img { position: relative; aspect-ratio: 1/1; background: #f3f3ee; }
.char-img img { width: 100%; height: 100%; object-fit: cover; }
.char-ph { display: flex; align-items: center; justify-content: center; height: 100%; color: #ccc; font-size: 38px; font-weight: 700; }
.badge-rare { position: absolute; top: 8px; right: 8px; background: #c8a85a; color: #fff; font-size: 10px; font-weight: 700; padding: 3px 7px; border-radius: 4px; letter-spacing: 1px; }
.badge-rare.rare { background: #88b7e5; }
.char-meta { padding: 10px 12px; }
.char-name { font-weight: 700; font-size: 13px; }
.char-jp { color: var(--muted); font-size: 11px; margin-top: 2px; }
.char-desc { color: #555; font-size: 12px; margin-top: 6px; line-height: 1.45; }
.char-pick-price { margin-top: 6px; font-size: 11px; color: var(--muted); }
.char-pick-price strong { color: var(--accent); font-weight: 800; font-size: 13px; margin-left: 4px; }
.char-stock { margin-top: 4px; font-size: 11px; color: #4a8c4a; font-weight: 600; }
.char-card.sold .char-stock { color: #c44; }

/* sticky purchase bar */
.purchase-bar {
  position: sticky; bottom: 0; left: 0; right: 0;
  background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -4px 14px rgba(0,0,0,.06);
  padding: 12px 16px; margin: 32px -16px 0; display: flex; align-items: center; gap: 12px;
}
.pb-info { flex: 1; }
.pb-name { font-weight: 700; font-size: 13px; line-height: 1.3; }
.pb-price { color: var(--accent); font-weight: 800; font-size: 14px; margin-top: 2px; }

/* trending strip */
.trending-strip { padding: 18px 16px 4px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ts-label { font-weight: 700; font-size: 13px; color: var(--accent); }
.ts-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.ts-chips .chip { background: #fff; border: 1px solid var(--line); padding: 5px 12px; border-radius: 16px; font-size: 12px; color: #333; }
.ts-chips .chip:hover { background: #fff6f6; border-color: var(--accent); color: var(--accent); }

/* news strip on home */
.news-strip { padding: 28px 16px 12px; }
.ns-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px; }
.ns-head h2 { margin: 0; font-size: 18px; }
.ns-head .more { font-size: 13px; color: var(--muted); }
.ns-head .more:hover { color: var(--accent); }
.ns-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.ns-card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; transition: all .15s; }
.ns-card:hover { border-color: var(--accent); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,.05); }
.ns-type { display: inline-block; font-size: 10px; font-weight: 700; color: var(--muted); letter-spacing: 1px; text-transform: uppercase; margin-bottom: 6px; }
.ns-title { font-weight: 700; font-size: 14px; line-height: 1.4; color: var(--fg); margin-bottom: 6px; }
.ns-body { color: var(--muted); font-size: 12px; line-height: 1.5; }
.ns-date { color: var(--accent); font-size: 11px; font-weight: 600; margin-top: 8px; }

/* news.php */
.news-tabs { display: flex; gap: 4px; margin-bottom: 20px; flex-wrap: wrap; }
.news-tabs a { padding: 8px 14px; border-radius: 16px; font-size: 13px; color: var(--muted); }
.news-tabs a.on { background: var(--fg); color: #fff; font-weight: 600; }
.news-list { display: flex; flex-direction: column; gap: 14px; }
.news-item { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 18px 22px; }
.news-item.pinned { border-color: var(--accent); background: #fff8f8; }
.news-item .ni-type { font-size: 11px; color: var(--muted); font-weight: 700; letter-spacing: 1px; text-transform: uppercase; }
.news-item h3 { margin: 6px 0 8px; font-size: 18px; }
.news-item .pin { color: var(--accent); }
.news-item .ni-body { color: #444; line-height: 1.65; margin: 0 0 10px; }
.news-item .ni-img { max-width: 100%; border-radius: 8px; margin: 10px 0; }
.news-item .ni-product { display: inline-flex; align-items: center; gap: 8px; background: #fafaf7; padding: 6px 12px 6px 6px; border-radius: 8px; font-size: 13px; color: var(--fg); margin: 6px 0; }
.news-item .ni-product img { width: 32px; height: 32px; border-radius: 6px; object-fit: cover; }
.news-item .ni-meta { display: flex; gap: 12px; font-size: 12px; color: var(--muted); margin: 10px 0; flex-wrap: wrap; }
.news-item .ni-meta .ago { margin-left: auto; }
.news-item .ni-cta {
  display: inline-flex; align-items: center; gap: 6px;
  background: #03C75A; color: #fff; font-weight: 600; font-size: 13px;
  padding: 8px 14px; border-radius: 6px; margin-top: 6px;
}
.news-item .ni-cta:hover { background: #02b150; color: #fff; }
.news-list .empty { text-align: center; padding: 60px; color: var(--muted); background: #fff; border-radius: 12px; }

/* 관련 시리즈 + 공유 */
.related { margin-top: 36px; padding: 24px; background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.related h2 { margin: 0 0 16px; font-size: 17px; }
.rel-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px,1fr)); gap: 12px; }
.rel-card { background: #fafaf7; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; transition: transform .15s; }
.rel-card:hover { transform: translateY(-2px); border-color: var(--accent); }
.rel-img { aspect-ratio: 1/1; background: #fff; padding: 6px; display: flex; align-items: center; justify-content: center; }
.rel-img img { max-width: 100%; max-height: 100%; object-fit: contain; }
.rel-meta { padding: 8px 10px; }
.rel-name { font-size: 11px; font-weight: 600; line-height: 1.3; min-height: 28px; overflow: hidden; }
.rel-price { font-size: 11px; color: var(--accent); font-weight: 700; margin-top: 4px; }

.share-row { display: flex; gap: 8px; align-items: center; padding: 18px; background: #fff; border: 1px solid var(--line); border-radius: 10px; margin-top: 16px; flex-wrap: wrap; }
.share-label { font-size: 12px; color: var(--muted); font-weight: 600; }
.share-btn { padding: 8px 14px; border: 1px solid var(--line); border-radius: 6px; font-size: 12px; background: #fafaf7; color: var(--fg); cursor: pointer; }
.share-btn:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

/* 위시리스트 하트 버튼 */
.wl-btn { background: transparent; border: 0; color: #ddd; font-size: 16px; cursor: pointer; padding: 0; margin-left: auto; transition: color .15s, transform .15s; line-height: 1; }
.wl-btn:hover { color: var(--accent); transform: scale(1.2); }
.wl-btn.on { color: var(--accent); }

/* 백과 타임라인 */
.timeline { position: relative; padding-left: 24px; }
.timeline::before { content: ''; position: absolute; left: 6px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.tl-item { position: relative; padding: 8px 0; display: grid; grid-template-columns: 80px 1fr; gap: 12px; align-items: center; }
.tl-dot { position: absolute; left: -22px; top: 14px; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); border: 2px solid #fff; box-shadow: 0 0 0 2px var(--accent); }
.tl-item.self .tl-dot { background: var(--gold); box-shadow: 0 0 0 2px var(--gold); transform: scale(1.3); }
.tl-date { font-size: 11px; color: var(--muted); font-weight: 700; }
.tl-name { font-size: 13px; }
.tl-name a { color: var(--fg); }
.tl-name a:hover { color: var(--accent); }
.self-row .sb-label a { color: var(--accent); font-weight: 700; }

/* 상품상세 탭 */
.prod-tabs { background: #fff; border: 1px solid var(--line); border-radius: 12px; margin-top: 32px; overflow: hidden; }
.pt-nav { display: flex; border-bottom: 2px solid var(--line); background: #fafaf7; }
.pt-tab { flex: 1; padding: 16px 12px; background: transparent; border: 0; border-bottom: 3px solid transparent; font-size: 14px; font-weight: 600; color: var(--muted); cursor: pointer; transition: all .15s; }
.pt-tab:hover { color: var(--fg); }
.pt-tab.on { color: var(--accent); border-bottom-color: var(--accent); background: #fff; }
.pt-panel { display: none; padding: 28px 32px; }
.pt-panel.on { display: block; }
.pt-panel h3 { margin: 0 0 14px; font-size: 16px; }
.pt-panel .content-block { color: #333; line-height: 1.8; font-size: 14px; padding: 16px; background: #fafaf7; border-radius: 8px; white-space: pre-line; }

.acc { border-bottom: 1px solid var(--line); padding: 14px 4px; }
.acc:last-child { border-bottom: 0; }
.acc summary { font-weight: 700; cursor: pointer; padding: 6px 0; font-size: 14px; list-style: none; user-select: none; }
.acc summary::after { content: '▾'; float: right; transition: transform .2s; }
.acc[open] summary::after { transform: rotate(180deg); }
.acc ul { list-style: disc; padding-left: 22px; margin: 12px 0 4px; color: #444; line-height: 1.8; font-size: 13px; }
.acc strong { color: var(--accent); }
@media (max-width:760px) { .pt-panel { padding: 20px 16px; } .pt-tab { font-size: 12px; padding: 12px 8px; } }

/* admin filter bar */
.filter-bar { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; padding: 10px 14px; background: #fff; border-radius: 8px; box-shadow: 0 1px 3px rgba(0,0,0,.04); }
.fb-search { flex: 1; min-width: 200px; padding: 7px 12px; border: 1px solid var(--line); border-radius: 6px; font-size: 13px; }

/* mobile optimization */
@media (max-width: 760px) {
  .topbar .wrap { gap: 8px; height: 54px; padding: 0 12px; flex-wrap: nowrap; }
  .logo-img { width: 30px; height: 30px; }
  .naver-btn { padding: 5px 8px; font-size: 11px; }
  .naver-btn .naver-mark { width: 14px; height: 14px; font-size: 10px; }

  /* 햄버거 노출 + nav 드롭다운 패널화 */
  .nav-toggle { display: block; order: 99; }
  .nav {
    display: none;
    position: fixed; left: 0; right: 0; top: 54px;
    flex-direction: column; gap: 0; flex: none;
    background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: 0 8px 20px rgba(0,0,0,.08);
    padding: 8px 16px 16px; font-size: 15px;
    max-height: calc(100vh - 54px); overflow-y: auto;
    z-index: 49;
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px 4px; border-bottom: 1px solid #f1eee9; }
  .nav a:last-child { border-bottom: 0; }
  .nav a.on { border-bottom-color: #f1eee9; color: var(--accent); }
  body.nav-open { overflow: hidden; }

  .featured, .news-strip, .catalog { padding-left: 12px; padding-right: 12px; }
  .ft-grid, .ns-grid, .grid { gap: 10px; }

  .grid { grid-template-columns: repeat(2, 1fr); }
  .ft-grid { grid-template-columns: repeat(2, 1fr); }
  .ns-grid { grid-template-columns: 1fr; }

  .catalog-controls { gap: 6px; }
  .catalog-controls h2 { font-size: 16px; width: 100%; margin-bottom: 4px; }
  .cat-search { min-width: 0; }

  .hero-overlay { padding-bottom: 50px; padding-left: 12px; padding-right: 12px; }
  .hero-stats { gap: 10px !important; }

  .product-grid { grid-template-columns: 1fr; }
  .price-table.v2 .row { padding: 8px 0; font-size: 13px; }
  .stock-summary { grid-template-columns: 1fr; }

  .wiki-body { padding: 16px 12px; gap: 16px; }
  .wiki-section { padding: 18px 16px; }
  .wiki-section h2 { font-size: 17px; }

  .filter-bar { padding: 8px; gap: 6px; }
  .fb-search { min-width: 0; flex-basis: 100%; }

  .biz-info { font-size: 11px; }

  .meta .name { font-size: 12px; min-height: 32px; }
  .meta .price-line .p-rand { font-size: 13px; }
  .card-num { font-size: 9px; padding: 1px 5px; }
}

/* about */
.about-block { margin-bottom: 28px; }

/* === wiki === */
.wiki-link {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 14px; padding: 10px 16px;
  background: linear-gradient(90deg, #fff5f5, #fff);
  border: 1px solid var(--accent); border-radius: 8px;
  color: var(--accent); font-weight: 700; font-size: 13px;
}
.wiki-link:hover { background: var(--accent); color: #fff; }

.wiki-page { background: #fafaf7; }
.wiki-hero { position: relative; height: 320px; overflow: hidden; }
.wiki-cover { width: 100%; height: 100%; object-fit: cover; object-position: center; filter: blur(8px) brightness(0.65); transform: scale(1.15); }
.wiki-hero-overlay {
  position: absolute; inset: 0; display: flex; align-items: flex-end; padding: 40px 0;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,.55));
}
.wiki-hero-overlay h1 { color: #fff; font-size: 36px; margin: 8px 0 4px; letter-spacing: -0.5px; text-shadow: 0 2px 8px rgba(0,0,0,.4); }
.wiki-hero-overlay .jp { color: rgba(255,255,255,.7); margin: 0 0 4px; font-size: 13px; }
.wiki-hero-overlay .series { color: rgba(255,255,255,.85); margin: 0; font-size: 13px; }
.wiki-hero-overlay .brand-row .brand { color: #fff; padding: 3px 10px; border-radius: 12px; font-size: 11px; font-weight: 800; }
.wiki-hero-overlay .brand-row .maker, .wiki-hero-overlay .brand-row .release { color: rgba(255,255,255,.85); background: rgba(255,255,255,.15); }
@media (max-width:760px) { .wiki-hero { height: 220px; } .wiki-hero-overlay h1 { font-size: 24px; } }

.wiki-body { display: grid; grid-template-columns: 220px 1fr; gap: 36px; padding: 36px 16px 80px; max-width: 1080px; }
@media (max-width:900px) { .wiki-body { grid-template-columns: 1fr; } }

.wiki-toc { position: sticky; top: 80px; align-self: start; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 18px 16px; font-size: 13px; }
.wiki-toc h3 { margin: 0 0 10px; font-size: 12px; color: var(--muted); letter-spacing: 1px; text-transform: uppercase; }
.wiki-toc ol { list-style: none; padding: 0; margin: 0 0 16px; counter-reset: toc; }
.wiki-toc li { counter-increment: toc; margin: 8px 0; }
.wiki-toc li::before { content: counter(toc) "."; color: var(--muted); margin-right: 6px; font-weight: 600; }
.wiki-toc a { color: var(--fg); }
.wiki-toc a:hover { color: var(--accent); }
.back-to-product { display: block; padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }

.wiki-main { min-width: 0; }
.wiki-poster { background: #fff; border-radius: 12px; padding: 24px 20px; text-align: center; margin: 0 0 18px; border: 1px solid var(--line); }
.wiki-poster img { max-width: 100%; max-height: 480px; width: auto; height: auto; object-fit: contain; }
.wiki-poster figcaption { color: var(--muted); font-size: 12px; margin-top: 14px; letter-spacing: 0.5px; }
.wiki-section { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 24px 28px; margin-bottom: 18px; scroll-margin-top: 80px; }
.wiki-section h2 { margin: 0 0 16px; font-size: 20px; padding-bottom: 10px; border-bottom: 2px solid var(--accent); display: inline-block; }
.wiki-section h3 { margin: 20px 0 10px; font-size: 15px; color: var(--fg); }
.wiki-content { color: #333; line-height: 1.8; font-size: 14.5px; white-space: pre-line; }

.info-table { width: 100%; border-collapse: collapse; }
.info-table th { width: 100px; text-align: left; padding: 10px 12px; background: #fafaf7; color: var(--muted); font-size: 12px; font-weight: 600; border: 1px solid var(--line); }
.info-table td { padding: 10px 12px; border: 1px solid var(--line); font-size: 14px; }

/* charts */
.chart-block { background: #fafbfc; border-radius: 8px; padding: 16px 18px; margin: 20px 0; }
.rarity-bars, .stock-bars { display: flex; flex-direction: column; gap: 8px; }
.rb-row, .sb-row { display: grid; grid-template-columns: 80px 1fr 60px; align-items: center; gap: 10px; font-size: 13px; }
.rb-bar, .sb-bar { background: #e5e7eb; height: 16px; border-radius: 8px; overflow: hidden; }
.rb-fill, .sb-fill { height: 100%; border-radius: 8px; transition: width .4s; }
.rb-count, .sb-count { font-weight: 700; text-align: right; font-size: 12px; color: var(--muted); }

.price-comparison { width: 100%; border-collapse: collapse; }
.price-comparison th, .price-comparison td { padding: 12px; border: 1px solid var(--line); text-align: left; font-size: 14px; }
.price-comparison th { background: #fafaf7; font-size: 12px; color: var(--muted); }
.price-comparison tr.hi { background: #fff8f8; }
.price-comparison tr.hi td { font-weight: 600; }
.price-comparison strong { color: var(--accent); font-weight: 800; }

.wiki-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.wg-item { position: relative; margin: 0; border-radius: 10px; overflow: hidden; background: #f3f3ee; aspect-ratio: 4/3; }
.wg-item img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.wg-item.wg-video { aspect-ratio: 16/9; }
.wg-item.wg-video iframe { width: 100%; height: 100%; border: 0; }
.wg-item figcaption { position: absolute; bottom: 0; left: 0; right: 0; background: linear-gradient(180deg, transparent, rgba(0,0,0,.7)); color: #fff; padding: 8px 10px; font-size: 12px; }
.wg-source { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,.6); color: #fff; font-size: 10px; padding: 2px 6px; border-radius: 4px; }
.s-licensed { background: #2563eb; }
.s-official { background: #16a34a; }
.s-user { background: #ea580c; }

.wiki-footer { margin-top: 32px; padding: 18px; border-top: 1px solid var(--line); }

/* wiki index */
.wiki-index-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr)); gap: 16px; }
.wi-card { background: #fff; border-radius: 10px; overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,.05); transition: transform .15s; }
.wi-card:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,.08); }
.wi-card img { width: 100%; aspect-ratio: 1/1; object-fit: cover; }
.wi-meta { padding: 12px 14px; }
.wi-brand { font-size: 11px; color: var(--accent); font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; }
.wi-name { font-weight: 700; font-size: 14px; line-height: 1.4; margin: 4px 0 6px; }
.wi-stats { color: var(--muted); font-size: 11px; }
.about-block h2 { font-size: 18px; margin: 0 0 8px; color: #2a1820; }
.about-block p { color: #444; line-height: 1.7; margin: 6px 0; }
.about-block ul { color: #444; line-height: 1.8; padding-left: 20px; }
.about-block em { color: var(--accent); font-style: normal; font-weight: 700; }

/* CART */
.empty { text-align: center; padding: 80px 16px; color: var(--muted); }
.empty a { color: var(--accent); }
.cart-table { background: #fff; border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow); }
.cart-row { display: grid; grid-template-columns: 60px 1fr 80px 100px 30px; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.cart-row:last-child { border-bottom: 0; }
.cart-row img { width: 60px; height: 60px; object-fit: cover; border-radius: 8px; }
.cart-row .name { font-weight: 600; }
.cart-row .meta { color: var(--muted); font-size: 12px; }
.cart-row input[type="number"] { width: 60px; padding: 6px; text-align: center; border: 1px solid var(--line); border-radius: 6px; }
.cart-row .line-total { font-weight: 700; text-align: right; }
.cart-row .del { background: none; border: 0; font-size: 18px; color: #c44; padding: 4px; }
.cart-row.total { padding: 16px; background: #fafaf7; font-size: 16px; }
.cart-summary { display: flex; justify-content: space-between; align-items: center; padding: 24px 0 12px; font-size: 18px; }
.cart-summary strong { color: var(--accent); margin-left: 8px; }

/* FORMS */
.form { display: flex; flex-direction: column; gap: 14px; }
.form label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.form input, .form textarea { padding: 12px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.form input:focus, .form textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.pay-info { background: #fff7e6; border: 1px solid #f0c674; border-radius: 8px; padding: 14px; font-size: 13px; }
.pay-info p { margin: 4px 0 0; color: #6c5418; }
.error { background: #fbeaea; color: #a02a2a; padding: 12px; border-radius: 8px; font-size: 14px; }

/* FOOTER */
.footer { background: #fff; border-top: 1px solid var(--line); margin-top: 60px; padding: 24px 0; }
.footer .row { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; font-size: 13px; }
.footer .links { display: flex; gap: 16px; }
.footer .links a { color: var(--muted); }
.footer .copy { margin-top: 12px; color: var(--muted); font-size: 12px; }
.footer .version-tag { margin-top: 8px; color: var(--muted); font-size: 10px; opacity: 0.6; font-family: monospace; }
