﻿/*
Theme Name: SupSale Vintage Edit v4
Theme URI: https://bolg.supsale.jp/
Author: SupSale
Description: 中古ラグジュアリー＆ストリートブランドのための専用テーマ。2カラムグリッド、無限スクロール、モバイル最適化済み。
Version: 1.3.0
Text Domain: supsale-vintage
Domain Path: /languages
*/

/* ===== テーマ全体設定 ===== */
:root {
  --brand-primary: #1a1a2e;
  --brand-accent: #c9a96e;
  --brand-accent-light: #e8d5a3;
  --brand-bg: #faf8f5;
  --brand-card-bg: #ffffff;
  --brand-text: #1a1a2e;
  --brand-text-muted: #6b6b7b;
  --brand-border: #e8e4de;
  --brand-tag-bg: #f0ede8;
  --font-serif: "Noto Serif JP", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --font-sans: "Noto Sans JP", "Hiragino Sans", "Yu Gothic", sans-serif;
  --grid-gap: 28px;
  --card-radius: 0;
  --card-shadow: 0 1px 3px rgba(0,0,0,0.04);
  --content-max: 820px;
}

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.8;
  color: var(--brand-text);
  background: var(--brand-bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ===== ヘッダー ===== */
.site-header {
  background: var(--brand-primary);
  color: #fff;
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 3px solid var(--brand-accent);
}

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

.site-branding h1, .site-branding p { margin: 0; }

.site-branding a {
  color: #fff;
  text-decoration: none;
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.site-branding .site-description {
  font-size: 12px;
  color: var(--brand-accent-light);
  margin-top: 2px;
  font-weight: 300;
}

.main-navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 4px;
}

.main-navigation a {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.03em;
  transition: color 0.2s;
  border-radius: 4px;
}

.main-navigation a:hover { color: var(--brand-accent); background: rgba(255,255,255,0.06); }

/* ===== メインコンテンツ ===== */
.site-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 36px 20px 60px;
}

/* ===== ヒーローセクション ===== */
.hero-section {
  margin-bottom: 32px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--brand-border);
}
.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(24px, 4vw, 36px);
  margin: 0 0 6px;
  font-weight: 700;
  color: var(--brand-primary);
}
.hero-desc {
  font-size: 15px;
  color: var(--brand-text-muted);
  margin: 0;
}
.no-posts-found {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 0;
  color: var(--brand-text-muted);
}

/* ===== 記事グリッド ===== */
.post-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--grid-gap);
}

/* 記事カード */
.post-card {
  background: var(--brand-card-bg);
  border: 1px solid var(--brand-border);
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
  box-shadow: var(--card-shadow);
}

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

.post-card-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.post-card-thumb {
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--brand-tag-bg);
  position: relative;
  line-height: 0;
}

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

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

.post-card-thumb .no-image {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: var(--brand-text-muted);
  font-size: 12px;
  background: linear-gradient(135deg, #f0ede8 0%, #e8e4de 100%);
}

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

.post-card-category {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--brand-accent);
  text-transform: uppercase;
  margin-bottom: 8px;
  display: block;
}

.post-card-title {
  font-family: var(--font-serif);
  font-size: 18px;
  line-height: 1.4;
  margin: 0 0 10px;
  font-weight: 700;
  color: var(--brand-text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.post-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--brand-text-muted);
  border-top: 1px solid var(--brand-border);
  padding-top: 12px;
  margin-top: auto;
}

.post-card-date { font-size: 12px; }

.post-card-read {
  color: var(--brand-accent);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.03em;
}

/* ===== 無限スクロール ===== */
#infinite-scroll-sentinel {
  grid-column: 1 / -1;
  text-align: center;
  padding: 40px 0;
  font-size: 14px;
  color: var(--brand-text-muted);
}

.infinite-scroll-loading::after { content: "読み込み中…"; animation: blink 1.2s ease-in-out infinite; }
.infinite-scroll-end::after { content: "すべての記事を表示しました"; color: var(--brand-text-muted); }
.infinite-scroll-error::after { content: "読み込みに失敗しました"; color: #cc3333; }

@keyframes blink { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

/* ===== シングル記事 ===== */
.single-post-wrapper { max-width: var(--content-max); margin: 0 auto; }
.single-post-header { margin-bottom: 32px; padding-bottom: 24px; border-bottom: 1px solid var(--brand-border); }
.single-post-header .post-category { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; color: var(--brand-accent); text-transform: uppercase; }
.single-post-header h1 { font-family: var(--font-serif); font-size: clamp(28px, 5vw, 44px); line-height: 1.15; margin: 12px 0 16px; font-weight: 700; }
.single-post-header .post-meta { font-size: 13px; color: var(--brand-text-muted); }
.single-post-featured { margin: 20px 0 0; }
.single-post-featured img { width: 100%; height: auto; border-radius: 4px; }

.post-content { font-size: 17px; line-height: 2; }
.post-content p { margin: 0 0 1.6em; }
.post-content h2 { font-family: var(--font-serif); font-size: clamp(24px, 3.5vw, 32px); line-height: 1.3; margin: 48px 0 16px; padding-bottom: 8px; border-bottom: 2px solid var(--brand-accent); }
.post-content h3 { font-family: var(--font-serif); font-size: clamp(20px, 3vw, 26px); margin: 36px 0 12px; }
.post-content img { max-width: 100%; height: auto; border-radius: 4px; margin: 24px 0; }
.post-content figure { margin: 28px 0; }
.post-content figcaption { font-size: 13px; color: var(--brand-text-muted); text-align: center; margin-top: 6px; }
.post-content blockquote { margin: 28px 0; padding: 16px 20px; border-left: 3px solid var(--brand-accent); background: #f8f6f2; font-style: italic; }
.post-content ul, .post-content ol { margin: 0 0 1.6em; padding-left: 24px; }
.post-content li { margin-bottom: 6px; }
.post-content a { color: var(--brand-accent); text-decoration: underline; text-underline-offset: 3px; }
.post-content a:hover { color: var(--brand-primary); }

/* ===== フッター ===== */
.site-footer { background: var(--brand-primary); color: rgba(255,255,255,0.7); padding: 40px 20px 30px; text-align: center; }
.footer-inner { max-width: 1200px; margin: 0 auto; }
.site-footer a { color: var(--brand-accent-light); text-decoration: none; }
.footer-brand { font-family: var(--font-serif); font-size: 16px; font-weight: 600; color: #fff; margin-bottom: 8px; }
.footer-copy { font-size: 12px; }

/* ===== ページネーション（フォールバック） ===== */
.pagination { grid-column: 1 / -1; text-align: center; padding: 32px 0; display: flex; justify-content: center; gap: 6px; }
.pagination a, .pagination span { padding: 8px 14px; border: 1px solid var(--brand-border); font-size: 14px; text-decoration: none; color: var(--brand-text); border-radius: 4px; }
.pagination .current { background: var(--brand-accent); color: #fff; border-color: var(--brand-accent); }
.pagination a:hover { background: var(--brand-tag-bg); }

/* ===== モバイル対応 ===== */
@media (max-width: 600px) {
  .site-content { padding: 20px 12px 40px; }
  .header-inner { padding: 12px 16px; flex-wrap: wrap; }
  .site-branding a { font-size: 18px; }
  .main-navigation { width: 100%; margin-top: 8px; }
  .main-navigation ul { flex-wrap: wrap; }
  .main-navigation a { font-size: 12px; padding: 6px 10px; }
  .post-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .post-card-body { padding: 14px 12px 16px; }
  .post-card-title { font-size: 15px; }
  .post-card-excerpt { font-size: 13px; -webkit-line-clamp: 2; }
  .post-card-thumb { aspect-ratio: 16 / 10; }
  .post-content { font-size: 15px; }
  .single-post-header h1 { font-size: 24px; }
}

/* ===== タブレット微調整 ===== */
@media (min-width: 601px) and (max-width: 1024px) {
  .post-grid { gap: 20px; }
  .post-card-title { font-size: 17px; }
}


