/* mdblogテーマ「マガジン（Magazine）」— ウェブ雑誌・太字×赤・フィーチャー記事つき。色はCSS変数で注入 */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: "Hiragino Kaku Gothic ProN","Hiragino Sans","Yu Gothic",YuGothic,Meiryo,sans-serif; font-size: 16px; line-height: 1.85; background: var(--bg); color: var(--text); word-wrap: break-word; overflow-wrap: break-word; }
a { color: var(--accent); text-decoration: none; transition: opacity .25s; }
a:hover { opacity: .75; }
img { max-width: 100%; height: auto; }
.wrapper { max-width: 1080px; margin: 0 auto; padding: 0 24px 64px; }
.wrapper article { max-width: var(--max-width); margin: 0 auto; }

.hero { max-width: 1080px; margin: -8px auto 36px; padding: 0 24px; }
.hero img { width: 100%; height: auto; display: block; }

.site-header { text-align: center; padding: 48px 24px 20px; }
.site-title { margin: 0; font-size: 32px; font-weight: 900; letter-spacing: 0.04em; }
.site-title a { color: var(--text); }
.site-title a:hover { color: var(--accent); opacity: 1; }
.site-tagline { margin: 8px 0 0; font-size: 12px; color: var(--muted); letter-spacing: .2em; text-transform: uppercase; }
.site-social { margin: 10px 0 0; font-size: 12px; }
.site-social a { color: var(--muted); margin: 0 8px; }
.site-social a:hover { color: var(--accent); opacity: 1; }

.site-nav { border-top: 2px solid var(--text); border-bottom: 1px solid var(--rule); text-align: center; margin: 0 auto 40px; max-width: 1080px; }
.site-nav a { display: inline-block; padding: 12px 24px; font-size: 13px; font-weight: 700; letter-spacing: .12em; color: var(--text); }
.site-nav a:hover { color: var(--accent); opacity: 1; }

/* フィーチャー記事（トップの最新1件） */
.featured { display: grid; grid-template-columns: 3fr 2fr; gap: 28px; align-items: center; color: var(--text); margin: 0 0 36px; padding-bottom: 32px; border-bottom: 2px solid var(--text); }
.featured:hover { opacity: 1; }
.featured:hover .featured-title { color: var(--accent); }
.featured-image { display: block; aspect-ratio: 16/9; overflow: hidden; background: var(--rule); }
.featured-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.featured-image-empty { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--accent), #333); }
.featured-image-empty span { color: #fff; font-size: 64px; font-weight: 900; }
.featured-body { display: block; }
.featured .post-meta { display: block; }
.featured-title { display: block; margin-top: 8px; font-size: 26px; font-weight: 900; line-height: 1.45; transition: color .25s; }
.featured-excerpt { display: block; margin-top: 10px; font-size: 14px; color: var(--muted); }
@media (max-width: 640px) { .featured { grid-template-columns: 1fr; gap: 14px; } }

/* カードグリッド */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 28px 24px; }
.card { display: block; color: var(--text); }
.card:hover { opacity: 1; }
.card:hover .card-title { color: var(--accent); }
.card-image { display: block; aspect-ratio: 16/9; overflow: hidden; background: var(--rule); }
.card-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card-image-empty { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--accent), #333); }
.card-image-empty span { color: #fff; font-size: 36px; font-weight: 900; }
.card-body { display: block; padding: 10px 2px 0; }
.card .post-meta { display: block; font-size: 11px; color: var(--muted); letter-spacing: .06em; }
.card-title { display: block; margin-top: 4px; font-size: 15px; font-weight: 700; line-height: 1.5; transition: color .25s; }

.post-meta { font-size: 12px; color: var(--muted); }
.post-meta a { color: var(--accent); font-weight: 700; }
.front-profile { text-align: center; font-size: 14px; color: var(--muted); margin: 0 0 26px; }
.more-link { text-align: center; margin: 36px 0 0; font-size: 14px; font-weight: 700; }
.page-heading { font-size: 16px; font-weight: 900; letter-spacing: .14em; text-align: center; color: var(--text); margin: 0 0 24px; }

.post-list { list-style: none; margin: 0 auto; padding: 0; max-width: var(--max-width); }
.post-list li { padding: 24px 0; border-bottom: 1px solid var(--rule); }
.post-list h2 { margin: 6px 0 6px; font-size: 20px; font-weight: 700; line-height: 1.5; }
.post-list h2 a { color: var(--text); }
.post-list h2 a:hover { color: var(--accent); }
.post-excerpt { margin: 0; font-size: 14px; color: var(--muted); }

.post-header { margin-bottom: 32px; text-align: center; }
.post-header h1 { font-size: 28px; font-weight: 900; line-height: 1.5; margin: 8px 0 0; }

.prose h2 { font-size: 22px; font-weight: 900; margin: 2.4em 0 .8em; line-height: 1.5; border-left: 6px solid var(--accent); padding-left: .6em; }
.prose h3 { font-size: 18px; font-weight: 700; margin: 2em 0 .6em; }
.prose p { margin: 1.25em 0; }
.prose blockquote { margin: 1.5em 0; padding: .8em 1.2em; background: #F7F7F7; border-left: 4px solid var(--text); color: var(--muted); }
.prose hr { border: none; border-top: 2px solid var(--text); margin: 3em auto; max-width: 160px; }
.prose ul, .prose ol { padding-left: 1.6em; }
.prose li { margin: .3em 0; }
.prose code { background: #F2F2F2; padding: .15em .4em; border-radius: 3px; font-size: .9em; }
.prose pre { background: #111; color: #eee; padding: 1em 1.2em; border-radius: 6px; overflow-x: auto; line-height: 1.6; }
.prose pre code { background: none; padding: 0; }
.prose table { border-collapse: collapse; width: 100%; font-size: 14px; }
.prose th, .prose td { border: 1px solid var(--rule); padding: .5em .8em; }
.prose th { background: #F7F7F7; font-weight: 700; }
.prose img { display: block; margin: 1.5em auto; }

.embed-youtube { aspect-ratio: 16/9; margin: 1.5em 0; }
.embed-youtube iframe { width: 100%; height: 100%; border: 0; }
.embed-map { aspect-ratio: 4/3; margin: 1.5em 0; }
.embed-map iframe { width: 100%; height: 100%; border: 0; }
.twitter-tweet, .instagram-media { margin: 1.5em auto !important; }

.pr-note { text-align: center; font-size: 12px; color: var(--muted); border: 1px solid var(--rule); padding: 6px 12px; margin: 0 auto 1.5em; max-width: var(--max-width); }
.toc { border: 2px solid var(--text); padding: 14px 20px; margin: 0 auto 2em; font-size: 14px; max-width: var(--max-width); }
.toc-title { margin: 0 0 4px; font-size: 12px; font-weight: 900; letter-spacing: .2em; }
.toc ol { margin: 0; padding-left: 1.4em; }
.toc li { margin: .2em 0; }
.toc li.toc-sub { list-style: none; font-size: 13px; padding-left: 1em; }
.toc a { color: var(--text); }
.toc a:hover { color: var(--accent); }

.share { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 1.8em auto; max-width: var(--max-width); }
.share a, .share button { display: inline-block; padding: 6px 16px; font-size: 12px; font-weight: 700; border: 1px solid var(--text); background: none; color: var(--text); cursor: pointer; font-family: inherit; transition: all .2s; }
.share a:hover, .share button:hover { background: var(--accent); border-color: var(--accent); color: #fff; opacity: 1; }

.author-box { display: flex; gap: 16px; align-items: flex-start; border: 2px solid var(--text); padding: 18px 20px; margin: 2.5em auto 0; max-width: var(--max-width); }
.author-icon { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.author-label { display: block; font-size: 11px; color: var(--muted); letter-spacing: .14em; }
.author-name { font-size: 15px; font-weight: 900; }
.author-bio { margin: 6px 0 0; font-size: 13px; color: var(--muted); }
.author-links { margin: 8px 0 0; font-size: 12px; }
.author-links a { margin-right: 10px; }

.related { margin: 2.5em auto 0; border-top: 2px solid var(--text); padding-top: 1.5em; max-width: var(--max-width); }
.related-title { font-size: 13px; font-weight: 900; letter-spacing: .12em; margin: 0 0 8px; }
.related ul { list-style: none; margin: 0; padding: 0; }
.related li { padding: 8px 0; border-bottom: 1px solid var(--rule); font-size: 14px; }
.related li .post-meta { margin-left: 8px; }
.related a { color: var(--text); font-weight: 700; }
.related a:hover { color: var(--accent); }

.post-nav { display: flex; justify-content: space-between; gap: 16px; margin: 2em auto 0; font-size: 13px; max-width: var(--max-width); }
.post-nav a { color: var(--muted); font-weight: 700; }
.post-nav a:hover { color: var(--accent); }
.post-nav-next { text-align: right; margin-left: auto; }

.post-footer { margin-top: 52px; padding-top: 18px; border-top: 1px solid var(--rule); font-size: 12px; color: var(--muted); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; max-width: var(--max-width); margin-left: auto; margin-right: auto; }
.post-footer a { color: var(--muted); margin-right: 8px; }
.post-footer a:hover { color: var(--accent); }

.site-footer { border-top: 2px solid var(--text); text-align: center; padding: 26px 24px 46px; font-size: 12px; color: var(--muted); letter-spacing: .1em; }
.site-footer a { color: var(--muted); margin: 0 8px; }

.ad-slot { margin: 2.5em auto; text-align: center; max-width: var(--max-width); }
