/* ==========================================================================
   屋根裏の本棚 - stylesheet
   モノトーン + アクセント1色（本の背表紙をイメージした藍色）
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&family=Noto+Sans+JP:wght@400;500;600;700&display=swap');

html {
    scroll-behavior: smooth;
    scrollbar-gutter: stable;
}

:root {
    /* --- カラー：モノトーン + アクセント1色 --- */
    --bg: #eef0f2;
    --surface: #ffffff;
    --surface-alt: #e6e8eb;
    --ink: #15171a;
    --ink-soft: #383c42;
    --muted: #9a9ea4;
    --line: #d6d9dd;
    --line-soft: #e5e7ea;
    --accent: #45474b;      /* 藍色寄りの木炭色：ほぼモノトーンの締め色 */
    --accent-soft: #e8e8e9;

    /* --- タイポグラフィ --- */
    --font-heading: "Shippori Mincho", "Hiragino Mincho ProN", "Yu Mincho", serif;
    --font-body: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Helvetica Neue", Arial, Meiryo, sans-serif;
    --font-mono: "Courier New", monospace;

    /* --- 形状 --- */
    --radius: 2px;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background-color: var(--bg);
    color: var(--ink-soft);
    font-family: var(--font-body);
    line-height: 1.75;
    font-size: 16px;
}

a { color: inherit; }

img { max-width: 100%; }

/* ==========================================================================
   1. レイアウトの基本
   ========================================================================== */
.container {
    width: min(100% - 40px, 900px);
    margin: 0 auto;
    padding: 56px 0 88px;
}

.site-header {
    text-align: center;
    margin-bottom: 36px;
}
.site-header h1 {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.9rem;
    letter-spacing: 0.12em;
    color: var(--ink);
    margin: 0 0 8px;
}
.catchphrase {
    font-size: 0.82rem;
    color: var(--muted);
    letter-spacing: 0.04em;
}

.site-footer {
    text-align: center;
    margin-top: 72px;
    padding-top: 24px;
    border-top: 1px solid var(--line-soft);
    font-size: 0.75rem;
    color: var(--muted);
}

.main-content section { margin-bottom: 56px; }
.main-content h2 {
    display: flex;
    align-items: baseline;
    gap: 12px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: 0.08em;
    color: var(--ink);
    border-bottom: 1px solid var(--line);
    padding-bottom: 10px;
    margin: 0 0 24px;
}
.main-content h2::before {
    content: "";
    width: 16px;
    height: 2px;
    background: var(--accent);
    flex-shrink: 0;
}

/* ==========================================================================
   2. ナビゲーション
   ========================================================================== */
#nav-placeholder {
    width: 100%;
    margin-bottom: 36px;
    text-align: center;
}

.nav-container { position: relative; z-index: 50; }

.site-nav {
    display: flex;
    justify-content: center;
    align-items: stretch;
    list-style: none;
    padding: 0;
    margin: 0;
    background: transparent;
    border-top: 1px solid var(--ink);
    border-bottom: 1px solid var(--ink);
}

.site-nav > li {
    position: relative;
    min-width: 0;
    border-left: 1px solid var(--line);
}
.site-nav > li:last-child { border-right: 1px solid var(--line); }

.site-nav a,
.site-nav summary {
    box-sizing: border-box;
    color: var(--ink-soft);
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
    display: block;
    padding: 14px 20px;
    letter-spacing: 0.1em;
    line-height: 1.4;
    cursor: pointer;
    white-space: nowrap;
    box-shadow: inset 0 -2px 0 transparent;
    transition: color 0.15s ease, box-shadow 0.15s ease;
}

.site-nav a:hover,
.site-nav summary:hover,
.site-nav a:focus-visible,
.site-nav summary:focus-visible {
    color: var(--ink);
    box-shadow: inset 0 -2px 0 var(--line);
}

.site-nav summary { list-style: none; }
.site-nav summary::-webkit-details-marker { display: none; }
.site-nav summary::after {
    content: "+";
    margin-left: 6px;
    color: var(--muted);
    font-size: 0.72rem;
    font-family: var(--font-body);
}
.nav-group[open] > summary::after { content: "\2212"; }

.nav-group { position: relative; }

.nav-submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--surface);
    border: 1px solid var(--line);
    padding: 0;
    list-style: none;
    min-width: 200px;
    box-shadow: 0 6px 16px rgba(20, 22, 26, 0.1);
    z-index: 100;
}

.nav-group[open] .nav-submenu,
.nav-group:hover .nav-submenu,
.nav-group:focus-within .nav-submenu {
    display: block;
}

.nav-submenu li { position: relative; border-bottom: 1px solid var(--line-soft); }
.nav-submenu li:last-child { border-bottom: none; }
.nav-submenu li::before {
    content: "";
    position: absolute;
    left: 0; top: 50%; transform: translateY(-50%);
    width: 3px; height: 0;
    background: var(--accent);
    transition: height 0.15s ease;
}
.nav-submenu li:hover::before { height: 60%; }

.nav-submenu li a {
    padding: 11px 16px 11px 18px;
    font-family: var(--font-body);
    font-size: 0.78rem;
    font-weight: normal;
    letter-spacing: 0.02em;
    white-space: nowrap;
    box-shadow: none;
}
.nav-submenu li a:hover { box-shadow: none; }

.nav-group::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 8px;
}

body.page-home .nav-home,
body.page-characters .nav-characters,
body.page-gallery .nav-works > summary,
body.page-movies .nav-works > summary,
body.page-trpg .nav-trpg > summary,
body.page-session .nav-trpg > summary,
body.page-spoiler .nav-trpg > summary,
body.page-diary .nav-notes > summary {
    color: var(--ink);
    box-shadow: inset 0 -2px 0 var(--accent);
}

/* ==========================================================================
   3. トップページ
   ========================================================================== */
.update-area {
    max-height: 150px;
    overflow-y: auto;
    border: 1px solid var(--line);
    padding: 15px;
    background: var(--surface);
}
.update-list { list-style: none; padding: 0; margin: 0; }
.update-list li {
    margin-bottom: 12px;
    font-size: 0.88rem;
    border-bottom: 1px solid var(--line-soft);
    padding-bottom: 8px;
    color: var(--ink-soft);
}
.update-list li:last-child { margin-bottom: 0; border-bottom: none; padding-bottom: 0; }
.update-list .date {
    font-weight: bold;
    color: var(--muted);
    margin-right: 15px;
    font-family: var(--font-mono);
}

.about-container { display: flex; gap: 32px; align-items: flex-start; }
.about-avatar img {
    width: 112px;
    height: 112px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--line);
    background: var(--surface);
}
.about-profile { flex: 1; }
.profile-name {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 8px;
    color: var(--ink);
}
.profile-text {
    font-size: 0.92rem;
    margin-bottom: 18px;
    color: var(--ink-soft);
}

.profile-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: 0.85rem;
    margin-top: 12px;
}
.link-group { display: flex; align-items: flex-start; flex-wrap: wrap; }
.link-label {
    font-weight: bold;
    color: var(--muted);
    width: 90px;
    flex-shrink: 0;
}
.link-items { display: flex; flex-wrap: wrap; gap: 0 12px; flex: 1; }
.link-items a { color: var(--ink-soft); text-decoration: none; padding: 2px 0; white-space: nowrap; }
.link-items a:hover { color: var(--accent); text-decoration: underline; }
.link-items a:not(:last-child)::after {
    content: "/";
    color: var(--line);
    margin-left: 12px;
    pointer-events: none;
}

.contact-links { display: flex; flex-direction: column; margin-top: 12px; border-top: 1px solid var(--line-soft); }
.contact-btn {
    position: relative;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 8px 16px 20px;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--line-soft);
    text-decoration: none;
    transition: padding-left 0.2s ease;
}
.contact-btn::before {
    content: "";
    position: absolute;
    left: 0; top: 50%; transform: translateY(-50%);
    width: 3px; height: 22px;
    background: var(--line);
    transition: background-color 0.2s ease, height 0.2s ease;
}
.contact-btn:hover { padding-left: 26px; }
.contact-btn:hover::before { background: var(--accent); height: 30px; }
.btn-label { font-size: 0.74rem; color: var(--muted); font-weight: bold; flex-shrink: 0; }
.btn-title { font-family: var(--font-heading); font-size: 0.98rem; color: var(--ink); font-weight: 700; }

/* ==========================================================================
   4. ギャラリー
   ========================================================================== */
.gallery-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0 14px;
    margin-bottom: 44px;
    padding: 10px 14px;
    position: sticky;
    top: 8px;
    z-index: 30;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    font-size: 0.78rem;
    letter-spacing: 0.06em;
}
.gallery-nav a { color: var(--muted); text-decoration: none; line-height: 2; }
.gallery-nav a:hover { color: var(--accent); text-decoration: underline; }
.gallery-nav a:not(:last-child)::after {
    content: "/";
    color: var(--line);
    margin-left: 14px;
    pointer-events: none;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 36px;
}
.gallery-item {
    background: var(--surface);
    border: 1px solid var(--line);
    padding: 8px;
    border-radius: var(--radius);
    transition: border-color 0.2s ease;
}
.gallery-item:hover { border-color: var(--accent); }
.modal-trigger {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    width: 100%;
    display: block;
    text-align: left;
    color: inherit;
    font: inherit;
}
.modal-trigger img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    display: block;
}
.gallery-caption { margin: 8px 0 0; font-size: 0.8rem; color: var(--ink-soft); }
.gallery-date {
    font-size: 0.72rem;
    color: var(--muted);
    display: block;
    font-family: var(--font-mono);
}

.spoiler-thumb {
    width: 100%;
    height: 150px;
    background: var(--surface-alt);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: var(--muted);
    border: 1px dashed var(--line);
}
.spoiler-thumb span { font-size: 0.78rem; font-weight: bold; letter-spacing: 0.12em; }
.spoiler-thumb p { font-size: 0.65rem; margin: 5px 0 0; }

/* --- モーダル --- */
.gallery-modal {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 0;
    max-width: 800px;
    box-shadow: 0 12px 28px rgba(20, 22, 26, 0.14);
    overflow: visible;
    background: var(--surface);
}
.gallery-modal::backdrop { background: rgba(20, 22, 26, 0.45); }
.modal-content { position: relative; padding: 28px; }
.modal-content img { max-width: 100%; height: auto; max-height: 70vh; display: block; margin: 0 auto; }
.modal-caption { margin-top: 14px; font-size: 0.85rem; color: var(--ink-soft); line-height: 1.6; text-align: center; }
.close-btn {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--ink);
    color: var(--surface);
    border: none;
    font-size: 0.75rem;
    padding: 6px 12px;
    cursor: pointer;
    letter-spacing: 0.05em;
    transition: background 0.15s;
}
.close-btn:hover { background: var(--accent); }

.modal-image-container { position: relative; display: block; max-width: 100%; }
.modal-control-panel {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 18px;
    margin-top: 14px;
    height: 30px;
}
.modal-counter {
    font-size: 0.85rem;
    color: var(--muted);
    font-family: var(--font-mono);
    font-weight: bold;
    min-width: 40px;
    text-align: center;
}
.slide-btn {
    background: var(--surface);
    color: var(--ink-soft);
    border: 1px solid var(--line);
    font-size: 0.75rem;
    padding: 4px 12px;
    cursor: pointer;
    border-radius: var(--radius);
    transition: all 0.15s;
    display: none;
}
.slide-btn:hover { background: var(--ink); color: var(--surface); border-color: var(--ink); }

/* ==========================================================================
   5. 動画ページ
   ========================================================================== */
.movie-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 20px;
    margin-bottom: 44px;
}
.movie-item {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.movie-poster { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; background: var(--ink); overflow: hidden; }
.movie-poster img { width: 100%; height: 100%; object-fit: cover; }
.play-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(20, 22, 26, 0.3);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.15s;
}
.play-overlay span {
    color: var(--surface);
    font-size: 1.8rem;
    background: rgba(29, 32, 36, 0.75);
    width: 50px;
    height: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    padding-left: 4px;
}
.movie-item:hover .play-overlay { opacity: 1; }
.movie-info { padding: 14px; display: flex; flex-direction: column; flex-grow: 1; gap: 4px; }
.movie-badge {
    font-size: 0.65rem;
    font-weight: bold;
    padding: 2px 8px;
    width: fit-content;
    margin: 0 0 4px;
    color: var(--surface);
    letter-spacing: 0.04em;
    background: var(--accent);
}
.movie-info h3 { margin: 0; font-size: 0.9rem; line-height: 1.35; color: var(--ink); font-weight: bold; }
.movie-description { margin: 0; font-size: 0.8rem; color: var(--ink-soft); line-height: 1.4; flex-grow: 1; }
.movie-date { font-size: 0.72rem; color: var(--muted); font-family: var(--font-mono); margin-top: 2px; }

/* --- 上に戻るボタン --- */
.scroll-to-top {
    position: fixed;
    bottom: 28px;
    right: 28px;
    width: 42px;
    height: 42px;
    background-color: var(--surface);
    color: var(--ink-soft);
    text-decoration: none;
    border: 1px solid var(--line);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.72rem;
    transition: all 0.2s ease;
    z-index: 100;
}
.scroll-to-top:hover { background-color: var(--ink); color: var(--surface); border-color: var(--ink); }

/* ==========================================================================
   6. 記事一覧（diary.html）
   ========================================================================== */
.diary-archive-list { display: flex; flex-direction: column; border-top: 1px solid var(--line-soft); }

.archive-item {
    position: relative;
    display: flex;
    align-items: center;
    padding: 16px 12px 16px 22px;
    text-decoration: none;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--line-soft);
    transition: background-color 0.15s ease, padding-left 0.2s ease;
}
.archive-item::before {
    content: "";
    position: absolute;
    left: 0; top: 50%; transform: translateY(-50%);
    width: 3px; height: 24px;
    background: var(--line);
    transition: background-color 0.2s ease, height 0.2s ease;
}
.archive-item:hover { background: var(--surface-alt); padding-left: 26px; }
.archive-item:hover::before { background: var(--accent); height: 32px; }

.archive-date {
    font-size: 0.78rem;
    color: var(--muted);
    font-family: var(--font-mono);
    margin-right: 18px;
    flex-shrink: 0;
}
.archive-title { font-size: 0.9rem; color: var(--ink-soft); font-weight: 500; flex-grow: 1; }
.archive-item:hover .archive-title { color: var(--ink); }

.archive-item:focus-visible,
.contact-btn:focus-visible,
.modal-trigger:focus-visible,
.scenario-card:focus-visible,
.back-to-list:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* --- カテゴリ切り替え --- */
.blog-category-nav {
    display: flex;
    gap: 18px;
    margin-bottom: 26px;
    font-size: 0.8rem;
    letter-spacing: 0.03em;
    flex-wrap: wrap;
}
.category-input { display: none; }
.category-label {
    cursor: pointer;
    color: var(--muted);
    padding: 4px 0;
    border-bottom: 1px solid transparent;
    font-weight: 500;
}
.category-label:hover { color: var(--ink); }

#tab-all:checked ~ .blog-category-nav [for="tab-all"],
#tab-diary:checked ~ .blog-category-nav [for="tab-diary"],
#tab-fanbox:checked ~ .blog-category-nav [for="tab-fanbox"],
#tab-work:checked ~ .blog-category-nav [for="tab-work"],
#tab-trpg:checked ~ .blog-category-nav [for="tab-trpg"] {
    color: var(--ink);
    font-weight: bold;
    border-bottom: 1px solid var(--accent);
}

#tab-diary:checked ~ .diary-archive-list .archive-item:not(.cat-diary),
#tab-fanbox:checked ~ .diary-archive-list .archive-item:not(.cat-fanbox),
#tab-work:checked ~ .diary-archive-list .archive-item:not(.cat-work),
#tab-trpg:checked ~ .diary-archive-list .archive-item:not(.cat-trpg) {
    display: none;
}

/* --- タグ --- */
.diary-archive-list .archive-tag,
.diary-list-section .tag-badge {
    font-size: 0.65rem;
    padding: 2px 8px;
    font-weight: bold;
    letter-spacing: 0.03em;
    display: inline-block;
    margin-right: 10px;
    border: 1px solid var(--line);
    color: var(--muted);
    background: var(--surface-alt);
}
.tag-trpg,
.archive-item.cat-diary .archive-tag,
.archive-item:hover .archive-tag {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-soft);
}

/* ==========================================================================
   7. ブログ個別記事
   ========================================================================== */
.diary-header { margin-bottom: 8px; }
.diary-date { font-size: 0.78rem; color: var(--muted); font-family: var(--font-mono); }
.diary-title {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--ink);
    margin: 32px 0 16px;
    padding-left: 12px;
    border-left: 3px solid var(--accent);
    letter-spacing: 0.04em;
}
.diary-header .diary-title { margin-top: 8px; }

.diary-body p { font-size: 0.96rem; color: var(--ink-soft); }
.diary-body img { max-width: 100%; height: auto; display: block; margin: 20px auto; border: 1px solid var(--line); }

.diary-video-wrapper, .diary-nico-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    margin: 20px 0;
    border: 1px solid var(--line);
    overflow: hidden;
}
.diary-video-wrapper iframe, .diary-nico-wrapper iframe {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: none;
}
.diary-audio-wrapper { width: 100%; margin: 20px 0; }
.diary-x-wrapper { display: flex; justify-content: center; margin: 20px 0; width: 100%; }
.diary-x-wrapper .twitter-tweet { margin: 0 auto !important; }

.diary-body blockquote {
    margin: 20px 0;
    padding: 14px 18px;
    background: var(--surface-alt);
    border-left: 3px solid var(--ink-soft);
    color: var(--ink-soft);
    font-size: 0.85rem;
}
.diary-body blockquote p { margin: 0 0 8px; }
.diary-body blockquote p:last-child { margin-bottom: 0; }

.diary-chat { display: flex; flex-direction: column; gap: 10px; margin: 20px 0; font-size: 0.85rem; }
.chat-line { display: flex; gap: 12px; }
.chat-name { font-weight: bold; color: var(--ink); width: 70px; flex-shrink: 0; text-align: right; }
.chat-text { color: var(--ink-soft); }

.diary-support-banner {
    display: inline-flex;
    align-items: center;
    margin: 6px 0 20px;
    padding: 2px 0;
    text-decoration: none;
}
.support-title {
    font-size: 0.85rem;
    letter-spacing: 0.03em;
    font-weight: bold;
    color: var(--accent);
    border-bottom: 1px solid transparent;
}
.diary-support-banner:hover .support-title { border-bottom-color: var(--accent); }

.diary-marshmallow {
    margin: 20px 0;
    padding: 18px;
    background: var(--surface-alt);
    border: 1px solid var(--line);
    position: relative;
}
.diary-marshmallow::before {
    content: "Q.";
    font-family: var(--font-mono);
    font-weight: bold;
    font-size: 1rem;
    color: var(--accent);
    display: block;
    margin-bottom: 5px;
}
.diary-marshmallow p { font-size: 0.85rem; color: var(--ink-soft); margin: 0; line-height: 1.6; }

.diary-body h3 {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--ink);
    margin: 36px 0 18px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--line);
    letter-spacing: 0.03em;
}

.post-footer {
    margin: 64px 0 30px;
    padding-top: 26px;
    border-top: 1px solid var(--line);
    text-align: center;
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
}
.back-to-list, .prev-post, .next-post {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px 8px 16px;
    background: transparent;
    border: 1px solid var(--line);
    border-left: 3px solid var(--line);
    color: var(--ink-soft);
    font-size: 0.75rem;
    text-decoration: none;
    letter-spacing: 0.05em;
    transition: border-color 0.15s ease, color 0.15s ease;
}
.back-to-list:hover, .prev-post:hover, .next-post:hover {
    border-color: var(--line);
    border-left-color: var(--accent);
    color: var(--accent);
}

/* ==========================================================================
   8. キャラクターページ
   ========================================================================== */
.char-card {
    background: var(--surface);
    border: 1px solid var(--line);
    margin-bottom: 20px;
    border-radius: var(--radius);
    overflow: hidden;
    list-style: none;
}
.char-card summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 22px;
    cursor: pointer;
    background: var(--surface-alt);
    border-bottom: 1px solid transparent;
}
.char-card[open] summary { border-bottom-color: var(--line); }
.char-card summary::after { content: "\25BC"; font-size: 0.65rem; color: var(--muted); margin-left: 15px; }
.char-card[open] summary::after { content: "\25B2"; }

.char-title-area { display: flex; align-items: center; gap: 14px; flex: 1; }
.char-title-area h3,
.char-title-area .char-name {
    font-family: var(--font-heading);
    margin: 0;
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: 0.06em;
}
.char-type-badge {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: bold;
    color: var(--surface);
    padding: 3px 9px;
    text-transform: uppercase;
    background: var(--muted);
}
.original { background-color: var(--accent); }
.coc { background-color: var(--ink); }
.doublecross { background-color: var(--ink-soft); }

.char-details { display: flex; gap: 0; }
.char-stand-img {
    width: 240px;
    height: 380px;
    object-fit: cover;
    display: block;
    border-right: 1px solid var(--line);
}
.char-info-block { flex: 1; padding: 22px; overflow-y: auto; height: 380px; }
.char-info-block h4 {
    margin: 0 0 10px;
    font-size: 0.85rem;
    color: var(--muted);
    border-bottom: 1px solid var(--line-soft);
    padding-bottom: 5px;
    letter-spacing: 0.08em;
}
.char-info-block p,
.char-info-block ul { font-size: 0.85rem; color: var(--ink-soft); line-height: 1.7; margin: 0 0 18px; }
.char-info-block p:last-child { margin-bottom: 0; }

/* ==========================================================================
   9. TRPGポータルページ
   ========================================================================== */
.trpg-section { width: 100%; margin-bottom: 40px; }

.trpg-profile-vertical { display: flex; flex-direction: column; gap: 16px; margin-bottom: 40px; width: 100%; }

.profile-block {
    background: var(--surface);
    border: 1px solid var(--line);
    padding: 22px;
    width: 100%;
}
.profile-block h3 {
    font-family: var(--font-heading);
    margin: 0 0 14px;
    padding-bottom: 8px;
    padding-left: 12px;
    border-bottom: 1px solid var(--line-soft);
    border-left: 3px solid var(--accent);
    font-size: 0.92rem;
    color: var(--ink);
    font-weight: 700;
}
.profile-lead, .books-text { font-size: 0.88rem; color: var(--ink-soft); }

.checkbox-row { display: flex; flex-wrap: wrap; gap: 14px 18px; align-items: center; }
.profile-block label {
    font-size: 0.85rem;
    color: var(--ink-soft);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}
.checkbox-cross { color: var(--muted) !important; font-weight: bold; }
.cross-input { accent-color: var(--muted); }

.days-circle { display: flex; gap: 8px; }
.days-circle span {
    width: 26px; height: 26px; font-size: 0.7rem; display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--line); border-radius: 50%; color: var(--muted);
}
.days-circle span.active { border-color: var(--accent); color: var(--accent); font-weight: bold; }

.status-tags { display: flex; align-items: center; gap: 8px; max-width: 300px; margin-top: 10px; }
.status-tag { font-size: 0.72rem; font-weight: bold; padding: 2px 10px; border: 1px solid var(--line); color: var(--muted); }
.status-tag.active { background: var(--accent); border-color: var(--accent); color: var(--surface); }
.status-line { flex-grow: 1; height: 1px; background: var(--line); }

.tendency-list { display: flex; flex-wrap: wrap; gap: 12px 20px; margin-top: 15px; list-style: none; padding: 0; }
.tendency-list label { font-size: 0.85rem; color: var(--ink-soft); display: inline-flex; align-items: center; gap: 6px; }

.trpg-hub-links, .trpg-scenario-links {
    display: flex;
    flex-direction: column;
    margin-top: 18px;
    border-top: 1px solid var(--line-soft);
}
.trpg-hub-links a,
.trpg-scenario-links a,
.scenario-card {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 16px 10px 16px 22px;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--line-soft);
    color: var(--ink-soft);
    text-decoration: none;
    font-size: 0.9rem;
    transition: padding-left 0.2s ease;
}
.trpg-hub-links a::before,
.trpg-scenario-links a::before,
.scenario-card::before {
    content: "";
    position: absolute;
    left: 0; top: 50%; transform: translateY(-50%);
    width: 3px; height: 24px;
    background: var(--line);
    transition: background-color 0.2s ease, height 0.2s ease;
}
.trpg-hub-links a:hover,
.trpg-scenario-links a:hover { padding-left: 28px; }
.trpg-hub-links a:hover::before,
.trpg-scenario-links a:hover::before,
.scenario-card:hover::before { background: var(--accent); height: 32px; }
.scenario-system {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--muted);
    letter-spacing: 0.08em;
    margin-bottom: 4px;
}
.scenario-title { font-family: var(--font-heading); font-weight: 700; color: var(--ink); }
.scenario-meta { font-size: 0.78rem; color: var(--muted); margin-top: 4px; }

.link-arrow { font-size: 0.7rem; color: var(--muted); margin: 0 8px; }

/* ==========================================================================
   10. セッションログ
   ========================================================================== */
.log-page-header { text-align: center; margin-bottom: 64px; padding-top: 30px; }
.log-page-header h1 {
    font-family: var(--font-heading);
    font-size: 2rem;
    letter-spacing: 0.2em;
    color: var(--ink);
    margin-bottom: 10px;
}
.log-page-header .catchphrase { font-size: 0.85rem; color: var(--muted); }

.log-archives {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 640px;
    margin: 0 auto;
}

.log-card {
    background: var(--surface);
    border: 1px solid var(--line);
    padding: 26px;
}
.log-system {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--muted);
    letter-spacing: 0.1em;
    margin-bottom: 4px;
}
.log-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    margin: 0 0 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--line-soft);
    color: var(--ink);
}
.log-content { display: flex; flex-direction: column; gap: 14px; }
.log-visual { width: 100%; }
.log-screenshot { width: 100%; display: block; border: 1px solid var(--line-soft); }
.log-info-box p { font-size: 0.85rem; color: var(--ink-soft); margin: 0 0 8px; }

.pc-list { list-style: none; padding: 0; margin: 0; }
.pc-list li { font-size: 0.85rem; line-height: 1.9; color: var(--ink-soft); display: flex; gap: 12px; }
.label { width: 42px; flex-shrink: 0; font-weight: bold; color: var(--accent); }

.log-result { font-size: 0.85rem; color: var(--ink-soft); margin: 0; }
.log-footer {
    margin-top: 6px;
    padding-top: 14px;
    border-top: 1px solid var(--line-soft);
    font-size: 0.78rem;
    color: var(--muted);
}
.log-footer p { margin: 0 0 4px; }
.log-date { font-family: var(--font-mono); }

/* ==========================================================================
   11. ネタバレ／感想ページ
   ========================================================================== */
.spoiler-box {
    background: var(--surface);
    border: 1px solid var(--line);
    margin-bottom: 16px;
    overflow: hidden;
}
.spoiler-box summary {
    padding: 15px 20px;
    cursor: pointer;
    font-weight: bold;
    color: var(--ink-soft);
    background: var(--surface-alt);
    list-style: none;
}
.spoiler-box summary::after { content: "\25BC"; float: right; font-size: 0.68rem; color: var(--muted); }
.spoiler-box[open] summary::after { content: "\25B2"; }
.spoiler-content {
    padding: 20px;
    border-top: 1px solid var(--line);
    color: var(--ink-soft);
    font-size: 0.9rem;
    line-height: 1.7;
}

/* ==========================================================================
   12. スマートフォン対応
   ========================================================================== */
@media (max-width: 600px) {
    .container { width: min(100% - 26px, 900px); padding: 32px 0 56px; }
    .site-header { margin-bottom: 26px; }
    .site-header h1 { font-size: 1.5rem; letter-spacing: 0.08em; }
    #nav-placeholder { margin-bottom: 30px; }

    .site-nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; padding: 0; }
    .site-nav > li { width: 100%; border: none; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
    .site-nav > li:nth-child(3n) { border-right: none; }
    .site-nav a, .site-nav summary { width: 100%; padding: 12px 5px; font-size: 0.68rem; text-align: center; letter-spacing: 0.02em; }
    .site-nav summary::after { margin-left: 3px; }
    .nav-submenu { top: calc(100% + 5px); width: max-content; max-width: min(250px, calc(100vw - 32px)); }
    .nav-submenu li a { padding: 10px 12px; text-align: left; font-size: 0.75rem; }

    .about-container { flex-direction: column; align-items: center; text-align: center; }
    .link-group { flex-direction: column; align-items: center; width: 100%; margin-bottom: 4px; justify-content: center; }
    .link-label { width: 100%; margin-bottom: 4px; }
    .link-items { justify-content: center; }

    .gallery-modal { width: 95%; }
    .modal-content { padding: 15px; }

    .gallery-nav { justify-content: flex-start; flex-wrap: nowrap; gap: 6px; margin: 0 0 34px; padding: 8px; overflow-x: auto; }
    .gallery-nav a { flex: 0 0 auto; padding: 4px 8px; background: var(--surface); border: 1px solid var(--line); line-height: 1.6; }
    .gallery-nav a:not(:last-child)::after { display: none; }

    .gallery-grid, .movie-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .gallery-item { padding: 6px; }
    .modal-trigger img, .spoiler-thumb { height: 128px; }

    .movie-info { padding: 10px; }
    .movie-info h3 { font-size: 0.82rem; }

    .char-details { flex-direction: column; }
    .char-stand-img { width: 100%; height: min(110vw, 480px); object-fit: contain; border-right: 0; border-bottom: 1px solid var(--line); background: var(--surface-alt); }
    .char-info-block { height: auto; overflow: visible; padding: 18px; }
    .char-card summary { padding: 14px; }
    .char-title-area { align-items: flex-start; flex-direction: column; gap: 6px; }

    .log-card, .profile-block { padding: 18px; }

    .archive-item { flex-direction: column; align-items: flex-start; gap: 6px; padding: 14px; }
}

@media (max-width: 390px) {
    .gallery-grid, .movie-grid { grid-template-columns: 1fr; }
    .modal-trigger img, .spoiler-thumb { height: 190px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}


/* =========================================================
   屋根裏の本棚 / reference-image inspired skin
   既存の style.css の一番下に追記して使えます。
   ========================================================= */

:root {
    --bg: #f7f7f7;
    --surface: #f7f7f7;
    --surface-alt: #ececec;
    --ink: #303030;
    --ink-soft: #3d3d3d;
    --muted: #777777;
    --line: #4b4b4b;
    --line-soft: #d8d8d8;
    --accent: #303030;
    --accent-soft: #e8e8e8;

    --font-heading: "Montserrat", "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
    --font-body: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", sans-serif;

    --radius: 16px;
}

html,
body {
    background: var(--bg);
    color: var(--ink-soft);
    font-family: var(--font-body);
    line-height: 1.75;
}

body {
    letter-spacing: 0.02em;
}

/* ---------- 全体レイアウト ---------- */
.container {
    width: min(calc(100% - 64px), 1280px);
    margin: 0 auto;
    padding: 0 0 88px;

    display: grid;
    grid-template-columns: minmax(280px, 1fr) auto;
    grid-template-areas:
        "header nav"
        "sub    sub"
        "main   main"
        "footer footer";
    column-gap: 36px;
}

.site-header {
    grid-area: header;
    text-align: left;
    margin: 0;
    padding: 14px 0 12px;
    border-bottom: 3px solid var(--line);
    align-self: stretch;
}

.site-header h1 {
    margin: 0;
    font-family: var(--font-heading);
    font-size: clamp(1.55rem, 2.3vw, 2.15rem);
    font-weight: 800;
    letter-spacing: 0.015em;
    line-height: 1.2;
    color: var(--ink);
}

.catchphrase {
    margin: 3px 0 0;
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    color: var(--muted);
}

#nav-placeholder {
    grid-area: nav;
    width: auto;
    margin: 0;
    border-bottom: 3px solid var(--line);
    display: flex;
    justify-content: flex-end;
    align-items: flex-end;
    text-align: right;
}

.nav-container {
    width: auto;
}

.site-nav {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
}

.site-nav > li,
.site-nav > li:last-child {
    border: 0;
}

.site-nav a,
.site-nav summary {
    padding: 23px 14px 18px;
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--ink);
    box-shadow: none;
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.site-nav a:hover,
.site-nav summary:hover,
.site-nav a:focus-visible,
.site-nav summary:focus-visible {
    color: var(--ink);
    box-shadow: none;
    opacity: 0.55;
    transform: translateY(-1px);
}

.site-nav summary::after {
    font-family: var(--font-body);
    color: var(--muted);
}

body.page-home .nav-home,
body.page-characters .nav-characters,
body.page-gallery .nav-works > summary,
body.page-movies .nav-works > summary,
body.page-trpg .nav-trpg > summary,
body.page-session .nav-trpg > summary,
body.page-spoiler .nav-trpg > summary,
body.page-diary .nav-notes > summary {
    box-shadow: none;
    text-decoration: underline;
    text-underline-offset: 6px;
    text-decoration-thickness: 1px;
}

.nav-submenu {
    background: var(--bg);
    border: 2px solid var(--line);
    border-radius: 10px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.nav-submenu li {
    border-bottom: 1px solid var(--line-soft);
}

.nav-submenu li::before {
    display: none;
}

.nav-submenu li a {
    padding: 11px 15px;
    font-size: 0.74rem;
    background: var(--bg);
}

.nav-submenu li a:hover {
    background: var(--surface-alt);
    opacity: 1;
    transform: none;
}

.gallery-nav {
    grid-area: sub;
    position: sticky;
    top: 8px;
    margin: 26px 0 0;
    padding: 9px 0 10px;
    justify-content: flex-end;
    background: rgba(247, 247, 247, 0.94);
    border: 0;
    border-bottom: 1px solid var(--line-soft);
    border-radius: 0;
    backdrop-filter: blur(8px);
}

.gallery-nav a {
    color: var(--ink-soft);
    font-family: var(--font-heading);
    font-weight: 600;
}

.gallery-nav a:hover {
    color: var(--ink);
}

.main-content {
    grid-area: main;
    padding-top: 44px;
    min-width: 0;
}

.site-footer {
    grid-area: footer;
    margin-top: 72px;
    padding-top: 20px;
    border-top: 2px solid var(--line);
}

/* ---------- 見出し：スクショっぽいアウトライン文字 ---------- */
.main-content > section > h2 {
    display: block;
    margin: 0 0 34px;
    padding: 0;
    border: 0;

    font-family: var(--font-heading);
    font-size: clamp(2.15rem, 4.3vw, 3.35rem);
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.055em;

    color: var(--bg);
    -webkit-text-stroke: 1.35px var(--ink);
    text-shadow:
        -1px -1px 0 var(--ink),
         1px -1px 0 var(--ink),
        -1px  1px 0 var(--ink),
         1px  1px 0 var(--ink);
}

.main-content > section > h2::before {
    display: none;
}

.main-content h3,
.profile-name,
.movie-info h3,
.char-name,
.log-title,
.diary-title {
    font-family: var(--font-heading);
    color: var(--ink);
}

/* ---------- HOME：左に大きな絵、右に情報 ---------- */
.page-home .main-content {
    display: grid;
    grid-template-columns: minmax(280px, 365px) minmax(0, 1fr);
    column-gap: clamp(36px, 5vw, 68px);
    row-gap: 34px;
    align-items: start;
}

.page-home .info-section {
    grid-column: 2;
    grid-row: 1;
    margin: 0;
}

.page-home .info-section::before {
    content: "INFORMATION";
    display: block;
    margin-bottom: 34px;
    font-family: var(--font-heading);
    font-size: clamp(2.15rem, 4.3vw, 3.35rem);
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.055em;
    color: var(--bg);
    -webkit-text-stroke: 1.35px var(--ink);
    text-shadow:
        -1px -1px 0 var(--ink),
         1px -1px 0 var(--ink),
        -1px  1px 0 var(--ink),
         1px  1px 0 var(--ink);
}

.page-home .info-section > h2 {
    display: block;
    margin: 0 0 8px;
    padding: 0 0 8px;
    border: 0;
    border-bottom: 2px solid var(--line);
    font-size: 0;
    color: var(--ink);
    -webkit-text-stroke: 0;
    text-shadow: none;
}

.page-home .info-section > h2::before {
    display: none;
}

.page-home .info-section > h2::after {
    content: "Update";
    font-family: var(--font-heading);
    font-size: 1.42rem;
    font-weight: 800;
    letter-spacing: 0.015em;
}

.page-home .update-list {
    max-height: 145px;
    overflow-y: auto;
    margin: 0;
    padding: 6px 4px 6px 0;
    border-bottom: 2px solid var(--line);
    scrollbar-width: thin;
    scrollbar-color: #9d9d9d transparent;
}

.page-home .update-list li {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 12px;
    margin: 0;
    padding: 8px 4px;
    border: 0;
    font-size: 0.84rem;
    line-height: 1.65;
}

.page-home .update-list .date {
    margin: 0;
    color: var(--ink-soft);
    font-family: var(--font-heading);
    font-size: 0.8rem;
}

.page-home .about-section,
.page-home .about-container {
    display: contents;
}

.page-home .about-section > h2 {
    grid-column: 2;
    grid-row: 2;
    margin: 18px 0 0;
}

.page-home .about-avatar {
    grid-column: 1;
    grid-row: 1 / span 3;
    align-self: stretch;
}

.page-home .about-avatar img {
    width: 100%;
    height: 100%;
    min-height: 650px;
    aspect-ratio: 3 / 5;
    object-fit: cover;
    display: block;

    border: 4px solid var(--line);
    border-radius: 20px;
    background: #fff;
}

.page-home .about-profile {
    grid-column: 2;
    grid-row: 3;
    min-width: 0;
}

.page-home .profile-name {
    margin: 0 0 14px;
    font-size: 1.25rem;
    font-weight: 800;
}

.page-home .profile-text {
    font-size: 0.86rem;
    line-height: 1.75;
}

.page-home .link-label {
    color: var(--ink);
    font-family: var(--font-heading);
}

/* ---------- フラットで細いカード ---------- */
.gallery-item,
.movie-item,
.char-card,
.profile-block,
.log-card,
.spoiler-box {
    background: transparent;
    box-shadow: none;
}

.gallery-item {
    border: 0;
    padding: 0;
}

.gallery-item:hover {
    border-color: transparent;
}

.modal-trigger img,
.spoiler-thumb,
.movie-poster img,
.log-screenshot {
    border: 2px solid var(--line);
    border-radius: 12px;
}

.gallery-caption {
    margin-top: 9px;
    font-size: 0.78rem;
}

.movie-item {
    border: 2px solid var(--line);
    border-radius: 14px;
    overflow: hidden;
}

.movie-poster img {
    border: 0;
    border-radius: 0;
}

.char-card,
.profile-block,
.log-card,
.spoiler-box {
    border: 2px solid var(--line);
    border-radius: 14px;
}

.char-card summary,
.spoiler-box summary {
    background: var(--surface-alt);
}

.profile-block h3,
.diary-title {
    border-left-color: var(--ink);
}

.contact-btn,
.archive-item,
.trpg-hub-links a,
.trpg-scenario-links a,
.scenario-card {
    transition: background-color 0.18s ease, transform 0.18s ease, padding-left 0.18s ease;
}

.contact-btn:hover,
.archive-item:hover,
.trpg-hub-links a:hover,
.trpg-scenario-links a:hover,
.scenario-card:hover {
    background: var(--surface-alt);
}

/* ---------- モーダル ---------- */
.gallery-modal {
    background: var(--bg);
    border: 2px solid var(--line);
    border-radius: 14px;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.18);
}

.close-btn {
    background: var(--ink);
}

/* ---------- レスポンシブ ---------- */
@media (max-width: 900px) {
    .container {
        width: min(calc(100% - 36px), 760px);
        display: block;
        padding-bottom: 64px;
    }

    .site-header {
        padding: 18px 0 14px;
        border-bottom: 0;
    }

    #nav-placeholder {
        display: block;
        width: 100%;
        border-top: 2px solid var(--line);
        border-bottom: 2px solid var(--line);
    }

    .site-nav {
        justify-content: center;
        flex-wrap: wrap;
    }

    .site-nav a,
    .site-nav summary {
        padding: 12px 10px;
    }

    .gallery-nav {
        margin-top: 18px;
    }

    .main-content {
        padding-top: 38px;
    }

    .page-home .main-content {
        display: block;
    }

    .page-home .info-section,
    .page-home .about-section,
    .page-home .about-container,
    .page-home .about-profile,
    .page-home .about-avatar,
    .page-home .about-section > h2 {
        display: block;
    }

    .page-home .about-section {
        display: block;
    }

    .page-home .about-container {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        text-align: left;
        gap: 24px;
    }

    .page-home .about-avatar {
        margin: 36px 0;
    }

    .page-home .about-avatar img {
        width: min(100%, 460px);
        height: auto;
        min-height: 0;
        margin: 0 auto;
    }

    .page-home .about-section > h2 {
        margin-top: 48px;
    }
}

@media (max-width: 600px) {
    .container {
        width: min(calc(100% - 24px), 760px);
        padding-top: 0;
    }

    .site-header h1 {
        font-size: 1.55rem;
    }

    .catchphrase {
        font-size: 0.68rem;
    }

    .site-nav {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .site-nav > li {
        border-right: 1px solid var(--line-soft);
        border-bottom: 1px solid var(--line-soft);
    }

    .site-nav a,
    .site-nav summary {
        padding: 11px 5px;
        font-size: 0.66rem;
    }

    .main-content > section > h2,
    .page-home .info-section::before {
        font-size: clamp(2rem, 12vw, 2.8rem);
        -webkit-text-stroke-width: 1px;
    }

    .page-home .update-list li {
        grid-template-columns: 1fr;
        gap: 2px;
    }

    .page-home .about-avatar img {
        border-width: 3px;
        border-radius: 16px;
    }

    .gallery-grid,
    .movie-grid {
        gap: 18px 12px;
    }
}
/* =========================================================
   INDEX 1カラム + シンプル太字見出し + 旧デザイン風の下線
   ※ style-reference.css の一番最後に追加して使えます
   ========================================================= */

:root {
    /* 見出しも本文と同じ素直なゴシック体にする */
    --font-heading: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", "Meiryo", sans-serif;
    --font-body: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", "Meiryo", sans-serif;
}

/* h1：装飾フォントを使わず、普通の太字 */
.site-header h1 {
    font-family: var(--font-body);
    font-weight: 800;
    letter-spacing: 0.04em;
}

/* ナビも同じゴシックで統一 */
.site-nav a,
.site-nav summary,
.gallery-nav a {
    font-family: var(--font-body);
    font-weight: 700;
}

/* ---------------------------------------------------------
   見出し：アウトライン文字をやめて、旧CSSの下線スタイルへ
   --------------------------------------------------------- */
.main-content > section > h2,
.page-home .info-section > h2,
.page-home .about-section > h2 {
    display: flex;
    align-items: baseline;
    gap: 12px;

    margin: 0 0 24px;
    padding: 0 0 10px;
    border: 0;
    border-bottom: 1px solid var(--line);

    font-family: var(--font-body);
    font-size: 1.2rem;
    font-weight: 800;
    line-height: 1.5;
    letter-spacing: 0.06em;

    color: var(--ink);
    -webkit-text-stroke: 0;
    text-shadow: none;
}

.main-content > section > h2::before,
.page-home .info-section > h2::before,
.page-home .about-section > h2::before {
    content: "";
    display: block;
    width: 16px;
    height: 2px;
    flex: 0 0 16px;
    background: var(--accent);
}

/* 以前の疑似見出し INFORMATION / Update は使わない */
.page-home .info-section::before {
    content: none;
    display: none;
}

.page-home .info-section > h2 {
    font-size: 1.2rem;
}

.page-home .info-section > h2::after {
    content: none;
    display: none;
}

/* h3類も普通の太字ゴシック */
.main-content h3,
.profile-name,
.movie-info h3,
.char-name,
.log-title,
.diary-title,
.profile-block h3,
.btn-title,
.scenario-title {
    font-family: var(--font-body);
    font-weight: 700;
}

/* ---------------------------------------------------------
   INDEX：ページ全体を1カラムに戻す
   --------------------------------------------------------- */
.page-home .main-content {
    display: block;
    width: 100%;
    max-width: none;
    padding-top: 44px;
}

.page-home .info-section,
.page-home .about-section {
    display: block;
    width: 100%;
    margin: 0 0 56px;
}

/* display: contents を解除 */
.page-home .about-container {
    display: flex;
    align-items: flex-start;
    gap: 28px;
    width: 100%;
}

/* ABOUT画像は大きな左カラムではなく、小さめのプロフィール画像に */
.page-home .about-avatar {
    display: block;
    flex: 0 0 140px;
    margin: 0;
}

.page-home .about-avatar img {
    display: block;
    width: 140px;
    height: 140px;
    min-height: 0;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    margin: 0;
    border: 2px solid var(--line);
    border-radius: 14px;
    background: #fff;
}

.page-home .about-profile {
    display: block;
    flex: 1 1 auto;
    min-width: 0;
}

.page-home .profile-name {
    margin: 0 0 10px;
    font-size: 1.08rem;
    font-weight: 800;
}

/* 更新欄はシンプルに。下線のトーンを残す */
.page-home .update-list {
    max-height: 170px;
    overflow-y: auto;
    margin: 0;
    padding: 0 4px 4px 0;
    border: 0;
    border-bottom: 1px solid var(--line);
}

.page-home .update-list li {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 14px;
    margin: 0;
    padding: 10px 4px;
    border: 0;
    border-bottom: 1px solid var(--line-soft);
    font-size: 0.86rem;
    line-height: 1.65;
}

.page-home .update-list li:last-child {
    border-bottom: 0;
}

.page-home .update-list .date {
    margin: 0;
    font-family: var(--font-body);
    font-weight: 700;
    color: var(--ink-soft);
}

/* ---------------------------------------------------------
   スマホ
   --------------------------------------------------------- */
@media (max-width: 700px) {
    .page-home .main-content {
        display: block;
        padding-top: 32px;
    }

    .main-content > section > h2,
    .page-home .info-section > h2,
    .page-home .about-section > h2 {
        font-size: 1.08rem;
        -webkit-text-stroke: 0;
        text-shadow: none;
    }

    .page-home .about-container {
        display: block;
        text-align: left;
    }

    .page-home .about-avatar {
        width: 112px;
        margin: 0 0 18px;
    }

    .page-home .about-avatar img {
        width: 112px;
        height: 112px;
        border-width: 2px;
        border-radius: 12px;
    }

    .page-home .update-list li {
        grid-template-columns: 1fr;
        gap: 2px;
    }
}


/* ==========================================================================
   12. CHARACTERS - 一覧 / 個別ページ
   ========================================================================== */

/* ----- 一覧 ----- */
.character-list-intro {
    margin: -4px 0 28px;
    color: var(--muted);
    font-size: 0.82rem;
}

.character-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.character-list-card {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    min-height: 152px;
    overflow: hidden;
    border: 1px solid var(--line);
    background: var(--surface);
    color: inherit;
    text-decoration: none;
    transition: border-color .15s ease, transform .15s ease;
}

.character-list-card:hover {
    border-color: var(--ink-soft);
    transform: translateY(-1px);
}

.character-list-image {
    position: relative;
    display: grid;
    place-items: center;
    overflow: hidden;
    background: var(--surface-alt);
    border-right: 1px solid var(--line);
}

.character-list-image img {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    min-height: 152px;
    object-fit: cover;
}

.character-list-image img.is-missing {
    visibility: hidden;
}

.character-list-placeholder {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: grid;
    place-items: center;
    padding: 10px;
    color: var(--muted);
    font-size: .6rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-align: center;
}

.character-list-body {
    min-width: 0;
    padding: 18px;
}

.character-list-series {
    margin: 0 0 8px;
    color: var(--muted);
    font-size: .64rem;
    font-weight: 700;
    letter-spacing: .08em;
}

.character-list-name {
    margin: 0;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 1.08rem;
    font-weight: 800;
    line-height: 1.4;
}

.character-list-name-en {
    margin: 2px 0 12px;
    color: var(--muted);
    font-size: .64rem;
    font-weight: 700;
    letter-spacing: .12em;
}

.character-list-text {
    margin: 0;
    color: var(--ink-soft);
    font-size: .76rem;
    line-height: 1.7;
}


/* ----- 個別ページ ----- */
.page-character-detail .character-detail-page {
    width: 100%;
}

.character-back,
.character-bottom-nav a {
    color: var(--muted);
    font-size: .76rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-decoration: none;
}

.character-back {
    display: inline-block;
    margin-bottom: 28px;
}

.character-back:hover,
.character-bottom-nav a:hover {
    color: var(--ink);
}

.character-hero {
    display: grid;
    grid-template-columns: minmax(300px, 43%) minmax(0, 1fr);
    gap: 48px;
    align-items: start;
    margin-bottom: 64px;
}

.character-summary {
    min-width: 0;
    padding-top: 34px;
}

.character-heading {
    margin-bottom: 22px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--line);
}

.character-series {
    margin: 0 0 10px;
    color: var(--muted);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .11em;
}

.character-heading .character-name {
    display: block;
    margin: 0;
    padding: 0;
    border: 0;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: clamp(2rem, 5vw, 3.25rem);
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: .03em;
}

.character-heading .character-name::before {
    content: none;
}

.character-name-en {
    margin: 7px 0 0;
    color: var(--muted);
    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .15em;
}

.character-lead {
    margin: 0 0 28px;
    color: var(--ink-soft);
    font-size: .92rem;
    line-height: 2;
}

.character-data {
    margin: 0;
    border-top: 1px solid var(--line);
}

.character-data > div {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 16px;
    padding: 11px 0;
    border-bottom: 1px solid var(--line-soft);
}

.character-data dt {
    color: var(--muted);
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .1em;
}

.character-data dd {
    margin: 0;
    color: var(--ink);
    font-size: .88rem;
    font-weight: 600;
}

.character-section {
    margin-bottom: 54px;
}

.character-section > h2 {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin: 0 0 24px;
    padding: 0 0 10px;
    border: 0;
    border-bottom: 1px solid var(--line);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 1.2rem;
    font-weight: 800;
    letter-spacing: .06em;
}

.character-section > h2::before {
    content: "";
    display: block;
    width: 16px;
    height: 2px;
    flex: 0 0 16px;
    background: var(--accent);
}

.character-profile-text {
    max-width: 720px;
}

.character-profile-text p {
    margin: 0 0 1.2em;
    line-height: 2;
}

.character-profile-text p:last-child {
    margin-bottom: 0;
}


/* ==========================================================================
   共通画像ビューア：立ち絵 / 表情 / ネタバレ差分など
   ========================================================================== */

.image-viewer {
    min-width: 0;
    outline: none;
}

.image-viewer:focus-visible {
    outline: 1px solid var(--ink);
    outline-offset: 5px;
}

.viewer-kicker,
.reference-label {
    margin: 0 0 9px;
    color: var(--muted);
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .12em;
}

.viewer-stage {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) 42px;
    align-items: center;
    gap: 8px;
}

.viewer-image-wrap {
    position: relative;
    display: grid;
    place-items: center;
    overflow: hidden;
    background: var(--surface-alt);
    border: 1px solid var(--line);
}

.viewer-main-image {
    position: relative;
    z-index: 2;
    display: block;
    width: 100%;
    object-fit: contain;
}

.viewer-main-image.is-missing {
    visibility: hidden;
}

.viewer-image-placeholder {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: grid;
    place-items: center;
    padding: 20px;
    color: var(--muted);
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-align: center;
}

.viewer-arrow {
    width: 42px;
    height: 64px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--ink);
    font: inherit;
    font-size: 2rem;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
    transition: opacity .15s ease, background-color .15s ease;
}

.viewer-arrow:hover {
    background: var(--surface-alt);
}

.viewer-meta {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    min-height: 35px;
    padding: 9px 50px 0;
}

.viewer-current-label {
    min-width: 0;
    overflow: hidden;
    color: var(--ink);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.viewer-counter {
    flex-shrink: 0;
    color: var(--muted);
    font-family: var(--font-mono);
    font-size: .68rem;
    letter-spacing: .06em;
}

.viewer-stage-standing .viewer-image-wrap {
    min-height: 540px;
}

.viewer-stage-standing .viewer-main-image {
    height: 540px;
}

.expression-block {
    margin-top: 34px;
}

.expression-viewer {
    max-width: 670px;
    margin-inline: auto;
}

.viewer-stage-expression .viewer-image-wrap {
    min-height: 370px;
}

.viewer-stage-expression .viewer-main-image {
    height: min(52vw, 430px);
}

.viewer-selectors {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    margin-top: 14px;
    padding: 2px 50px 8px;
    scrollbar-width: thin;
    scroll-snap-type: x proximity;
}

.viewer-choice {
    appearance: none;
    flex: 0 0 auto;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--ink-soft);
    font: inherit;
    cursor: pointer;
    scroll-snap-align: start;
    transition:
        border-color .15s ease,
        background-color .15s ease,
        color .15s ease;
}

.viewer-choice:hover {
    border-color: var(--ink-soft);
}

.viewer-choice.is-active {
    border-color: var(--ink);
    background: var(--ink);
    color: var(--surface);
}

.viewer-selectors-text .viewer-choice {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
    padding: 7px 10px;
    font-size: .66rem;
    font-weight: 800;
    letter-spacing: .06em;
    white-space: nowrap;
}

.choice-number {
    opacity: .48;
    font-family: var(--font-mono);
}

.viewer-selectors-thumb {
    gap: 10px;
}

.viewer-selectors-thumb .viewer-choice {
    width: 94px;
    padding: 5px;
}

.choice-thumb {
    position: relative;
    display: grid;
    place-items: center;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--surface-alt);
}

.choice-thumb img {
    position: relative;
    z-index: 2;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.choice-thumb img.is-missing {
    visibility: hidden;
}

.choice-thumb-fallback {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: grid;
    place-items: center;
    padding: 5px;
    color: var(--muted);
    font-size: .55rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-align: center;
}

.choice-label {
    display: block;
    overflow: hidden;
    padding: 6px 2px 2px;
    font-size: .65rem;
    font-weight: 700;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
}


/* ----- 資料アコーディオン ----- */

.character-accordion {
    border-top: 1px solid var(--ink);
    border-bottom: 1px solid var(--line);
}

.character-accordion > summary {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 18px 46px 18px 0;
    cursor: pointer;
    list-style: none;
    color: var(--ink);
}

.character-accordion > summary::-webkit-details-marker {
    display: none;
}

.character-accordion > summary span {
    display: flex;
    align-items: baseline;
    gap: 16px;
    min-width: 0;
}

.character-accordion > summary strong {
    font-size: .96rem;
    font-weight: 900;
    letter-spacing: .06em;
}

.character-accordion > summary small {
    color: var(--muted);
    font-size: .72rem;
    font-weight: 500;
}

.character-accordion > summary::after {
    content: "+";
    position: absolute;
    top: 50%;
    right: 6px;
    transform: translateY(-50%);
    color: var(--ink);
    font-size: 1.4rem;
    font-weight: 400;
    line-height: 1;
}

.character-accordion[open] > summary::after {
    content: "−";
}

.character-accordion[open] > summary {
    border-bottom: 1px solid var(--line-soft);
}

.accordion-inner {
    padding: 30px 0 34px;
}

.reference-block {
    margin-bottom: 34px;
}

.reference-image-wrap,
.reference-thumb {
    position: relative;
    display: grid;
    place-items: center;
    overflow: hidden;
    background: var(--surface-alt);
    border: 1px solid var(--line);
}

.reference-image-wrap {
    min-height: 360px;
}

.reference-image-wrap img {
    position: relative;
    z-index: 2;
    display: block;
    width: 100%;
    max-height: 720px;
    object-fit: contain;
}

.reference-thumb {
    aspect-ratio: 4 / 3;
}

.reference-thumb img {
    position: relative;
    z-index: 2;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.reference-image-wrap img.is-missing,
.reference-thumb img.is-missing {
    visibility: hidden;
}

.reference-placeholder {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: grid;
    place-items: center;
    color: var(--muted);
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .12em;
}

.reference-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.reference-card {
    margin: 0;
}

.reference-card figcaption {
    padding-top: 8px;
    color: var(--muted);
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .08em;
}

.reference-notes {
    margin: 28px 0 0;
    padding: 20px 22px 20px 40px;
    background: var(--surface-alt);
    border-left: 2px solid var(--accent);
    color: var(--ink-soft);
    font-size: .83rem;
    line-height: 1.9;
}

.memo-block {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 28px;
    padding: 18px 0;
    border-bottom: 1px solid var(--line-soft);
}

.memo-block:first-child {
    padding-top: 0;
}

.memo-block:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.memo-block h3 {
    margin: 0;
    color: var(--ink);
    font-size: .75rem;
    font-weight: 900;
    letter-spacing: .09em;
}

.memo-block p {
    margin: 0;
    color: var(--ink-soft);
    font-size: .86rem;
    line-height: 1.9;
}

.spoiler-warning {
    margin: 0 0 20px;
    padding: 12px 15px;
    background: var(--surface-alt);
    border-left: 2px solid var(--ink);
    color: var(--ink);
    font-size: .8rem;
    font-weight: 700;
}

.spoiler-placeholder-box {
    min-height: 180px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 6px;
    padding: 28px;
    border: 1px dashed var(--line);
    color: var(--muted);
    text-align: center;
}

.spoiler-placeholder-box p {
    margin: 0;
    color: var(--ink);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .1em;
}

.spoiler-placeholder-box span {
    font-size: .75rem;
}

.character-bottom-nav {
    margin-top: 68px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
}


/* ----- CHARACTERS responsive ----- */
@media (max-width: 760px) {
    .character-list {
        grid-template-columns: 1fr;
    }

    .character-hero {
        grid-template-columns: 1fr;
        gap: 28px;
        align-items: start;
        margin-bottom: 54px;
    }

    .character-summary {
        padding-top: 0;
    }

    .viewer-stage-standing .viewer-image-wrap {
        min-height: 0;
    }

    .viewer-stage-standing .viewer-main-image {
        height: min(125vw, 620px);
    }

    .character-heading .character-name {
        font-size: clamp(2rem, 10vw, 3rem);
    }

    .reference-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .character-accordion > summary span {
        flex-direction: column;
        align-items: flex-start;
        gap: 3px;
    }

    .memo-block {
        grid-template-columns: 1fr;
        gap: 7px;
    }
}

@media (max-width: 520px) {
    .character-list-card {
        grid-template-columns: 92px minmax(0, 1fr);
        min-height: 132px;
    }

    .character-list-image img {
        min-height: 132px;
    }

    .character-list-body {
        padding: 14px;
    }

    .viewer-stage {
        grid-template-columns: 34px minmax(0, 1fr) 34px;
        gap: 4px;
    }

    .viewer-arrow {
        width: 34px;
        height: 54px;
        font-size: 1.65rem;
    }

    .viewer-meta,
    .viewer-selectors {
        padding-left: 38px;
        padding-right: 38px;
    }

    .viewer-stage-expression .viewer-image-wrap {
        min-height: 260px;
    }

    .viewer-stage-expression .viewer-main-image {
        height: min(82vw, 390px);
    }

    .viewer-selectors-thumb .viewer-choice {
        width: 82px;
    }

    .character-data > div {
        grid-template-columns: 90px minmax(0, 1fr);
    }

    .reference-grid {
        grid-template-columns: 1fr;
    }

    .reference-image-wrap {
        min-height: 240px;
    }

    .accordion-inner {
        padding-top: 24px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .viewer-choice,
    .viewer-arrow,
    .character-list-card {
        transition: none;
    }
}


/* =========================================================
   HOME WAYFINDING / SITEMAP 2026.09
   ========================================================= */
.cms-home-page{
    background:#f7f7f7;
    color:#3d3d3d;
}
.cms-home-page .container{
    width:min(calc(100% - 52px),1120px);
}
.cms-home-page .cms-home-hero{
    display:grid;
    grid-template-columns:1fr auto;
    align-items:end;
    gap:4px 28px;
    margin:0 0 18px;
    padding:6px 0 20px;
    border-bottom:1px solid #4b4b4b;
    text-align:left;
}
.cms-home-page .cms-home-eyebrow{
    grid-column:1/-1;
    margin:0 0 5px;
    color:#777;
    font-size:10px;
    font-weight:700;
    letter-spacing:.15em;
}
.cms-home-page .cms-home-hero h1{
    margin:0;
    font-size:clamp(1.65rem,3vw,2.35rem);
    line-height:1.2;
    letter-spacing:.04em;
}
.cms-home-page .cms-home-hero .catchphrase{
    grid-column:1;
    margin:4px 0 0;
    color:#666;
    font-size:.75rem;
}
.cms-home-page .cms-home-hero-note{
    grid-column:2;
    grid-row:2/4;
    margin:0;
    align-self:center;
    color:#777;
    font-size:10px;
    font-weight:700;
    letter-spacing:.08em;
    text-align:right;
}

.cms-home-page #nav-placeholder{
    margin-bottom:32px;
}
.cms-home-page .main-content{
    display:grid;
    gap:34px;
}
.cms-home-page .main-content > section{
    margin:0;
}
.cms-home-page .main-content > section > h2,
.cms-home-page .cms-home-section-head h2{
    margin:0 0 14px;
    padding:0 0 9px;
    border-bottom:1px solid #555;
    color:#303030;
    font-size:1rem;
    letter-spacing:.08em;
}
.cms-home-page .cms-home-section-head{
    margin-bottom:14px;
}
.cms-home-page .cms-home-section-head p:last-child,
.cms-home-page .cms-home-sitemap-lead{
    margin:.4rem 0 0;
    color:#666;
    font-size:.82rem;
    line-height:1.8;
}
.cms-home-page .cms-kicker{
    margin:0 0 4px;
    color:#777;
    font-size:10px;
    font-weight:800;
    letter-spacing:.13em;
}

.cms-home-start{
    padding:18px 0 2px;
}
.cms-home-start-grid{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:10px;
}
.cms-home-start-grid a{
    display:flex;
    min-height:122px;
    flex-direction:column;
    padding:15px;
    border:1px solid #bdbdbd;
    background:#fbfbfb;
    color:#303030;
    text-decoration:none;
}
.cms-home-start-grid a:hover{
    border-color:#555;
    background:#fff;
}
.cms-home-start-grid small{
    color:#777;
    font-size:9px;
    font-weight:800;
    letter-spacing:.12em;
}
.cms-home-start-grid strong{
    margin:8px 0 7px;
    font-size:.9rem;
}
.cms-home-start-grid span{
    margin-top:auto;
    color:#666;
    font-size:.72rem;
    line-height:1.6;
}

.cms-home-page .cms-home-updates{
    padding:0;
    border:0;
}
.cms-home-page .cms-home-updates .update-list{
    margin:0;
    border-top:1px solid #d1d1d1;
}
.cms-home-page .cms-home-updates .update-list li{
    display:grid;
    grid-template-columns:92px 82px minmax(0,1fr);
    gap:12px;
    align-items:start;
    margin:0;
    padding:12px 2px;
    border-bottom:1px solid #d1d1d1;
    line-height:1.7;
}
.cms-home-page .cms-home-update-category{
    width:auto;
    padding:2px 6px;
    border:1px solid #c7c7c7;
    color:#777;
    font-size:9px;
    font-weight:800;
    letter-spacing:.08em;
    text-align:center;
}
.cms-home-page .cms-home-updates .date{
    color:#555;
    font-size:.68rem;
    font-weight:800;
}

.cms-home-page .cms-home-about .about-container{
    display:grid;
    grid-template-columns:150px minmax(0,1fr);
    gap:28px;
    align-items:start;
    padding:24px;
    border:1px solid #999;
    background:#fafafa;
}
.cms-home-page .cms-home-about .about-avatar{
    width:150px;
    padding:0;
}
.cms-home-page .cms-home-about .about-avatar img{
    width:120px;
    height:120px;
    object-fit:cover;
    border:1px solid #555;
    border-radius:10px;
}
.cms-home-about-label{
    margin:0 0 8px;
    color:#777;
    font-size:9px;
    font-weight:800;
    letter-spacing:.12em;
}
.cms-home-page .cms-profile-heading{
    display:flex;
    justify-content:space-between;
    gap:18px;
    align-items:flex-start;
    padding-bottom:15px;
    margin-bottom:15px;
    border-bottom:1px solid #d0d0d0;
}
.cms-home-page .profile-name{
    margin:0 0 4px;
    font-size:1.35rem;
}
.cms-home-page .profile-text{
    margin:8px 0;
    font-size:.82rem;
    line-height:1.85;
}
.cms-home-page .cms-home-profile-body{
    margin-top:18px;
}
.cms-home-page .cms-home-profile-notice{
    margin-top:16px;
    padding-top:13px;
    border-top:1px solid #aaa;
    color:#666;
    font-size:.75rem;
}
.cms-home-page .cms-home-links{
    margin-top:12px;
    padding:15px 18px;
    border:1px solid #c7c7c7;
    background:#fafafa;
}
.cms-home-page .cms-home-links .link-group{
    display:grid;
    grid-template-columns:92px 1fr;
    gap:12px;
    align-items:start;
}
.cms-home-page .cms-home-links .link-group + .link-group{
    margin-top:10px;
    padding-top:10px;
    border-top:1px solid #ddd;
}
.cms-home-page .cms-home-links .link-items{
    display:flex;
    flex-wrap:wrap;
    gap:5px 12px;
}
.cms-home-page .cms-home-links .link-items a{
    font-size:.72rem;
}

.cms-home-sitemap-grid{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:10px;
    margin-top:14px;
}
.cms-home-sitemap-grid article{
    padding:16px;
    border:1px solid #bdbdbd;
    background:#fafafa;
}
.cms-home-sitemap-grid h3{
    margin:0 0 12px;
    font-size:.95rem;
}
.cms-home-sitemap-grid article>a{
    display:grid;
    grid-template-columns:1fr;
    gap:2px;
    padding:9px 0;
    border-top:1px solid #ddd;
    text-decoration:none;
}
.cms-home-sitemap-grid article>a:hover strong{
    text-decoration:underline;
}
.cms-home-sitemap-grid strong{
    color:#303030;
    font-size:.72rem;
    letter-spacing:.04em;
}
.cms-home-sitemap-grid span{
    color:#777;
    font-size:.66rem;
}

.cms-home-page .cms-home-contact .contact-links{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:10px;
}
.cms-home-page .cms-home-contact .contact-btn{
    min-height:92px;
    padding:15px;
}

@media(max-width:900px){
    .cms-home-start-grid,
    .cms-home-sitemap-grid{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }
}
@media(max-width:640px){
    .cms-home-page .container{
        width:min(calc(100% - 28px),1120px);
    }
    .cms-home-page .cms-home-hero{
        display:block;
        padding-top:0;
    }
    .cms-home-page .cms-home-hero-note{
        margin-top:10px;
        text-align:left;
    }
    .cms-home-start-grid,
    .cms-home-sitemap-grid,
    .cms-home-page .cms-home-contact .contact-links{
        grid-template-columns:1fr;
    }
    .cms-home-page .cms-home-updates .update-list li{
        grid-template-columns:88px 1fr;
    }
    .cms-home-page .cms-home-updates .update-list li>a,
    .cms-home-page .cms-home-updates .update-list li>span:not(.date):not(.cms-home-update-category){
        grid-column:1/-1;
    }
    .cms-home-page .cms-home-about .about-container{
        grid-template-columns:1fr;
        padding:18px;
    }
    .cms-home-page .cms-home-about .about-avatar{
        width:auto;
    }
    .cms-home-page .cms-profile-heading{
        display:block;
    }
    .cms-home-page .cms-home-links .link-group{
        grid-template-columns:1fr;
        gap:5px;
    }
}


/* =========================================================
   HOME v4.3.1 emergency layout correction
   Old .page-home grid rules must not leak into the new HOME.
   ========================================================= */
.cms-home-page .main-content{
    display:block !important;
    grid-template-columns:none !important;
    column-gap:0 !important;
    row-gap:0 !important;
    padding-top:34px;
}
.cms-home-page .main-content > section{
    display:block !important;
    width:100% !important;
    grid-column:auto !important;
    grid-row:auto !important;
    margin:0 0 42px !important;
}
.cms-home-page .info-section,
.cms-home-page .about-section,
.cms-home-page .cms-home-start,
.cms-home-page .cms-home-sitemap,
.cms-home-page .cms-home-contact{
    grid-column:auto !important;
    grid-row:auto !important;
}
.cms-home-page .info-section::before,
.cms-home-page .about-section::before{
    content:none !important;
    display:none !important;
}
.cms-home-page .cms-home-start-grid{
    grid-template-columns:repeat(4,minmax(0,1fr));
}
.cms-home-page .cms-home-sitemap-grid{
    grid-template-columns:repeat(4,minmax(0,1fr));
}
.cms-home-page .cms-home-about .about-container{
    width:100%;
}
@media(max-width:900px){
    .cms-home-page .cms-home-start-grid,
    .cms-home-page .cms-home-sitemap-grid{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }
}
@media(max-width:640px){
    .cms-home-page .main-content{
        padding-top:24px;
    }
    .cms-home-page .cms-home-start-grid,
    .cms-home-page .cms-home-sitemap-grid{
        grid-template-columns:1fr;
    }
}


/* =========================================================
   HOME v4.4 public sitemap / bookshelf treatment
   ========================================================= */
.cms-home-sitemap-title{
    display:grid;
    grid-template-columns:minmax(0,1fr) minmax(260px,420px);
    gap:24px;
    align-items:end;
    margin-bottom:16px;
    padding-bottom:12px;
    border-bottom:1px solid #4b4b4b;
}
.cms-home-sitemap-title h2{
    margin:0 !important;
    padding:0 !important;
    border:0 !important;
}
.cms-home-sitemap-title>p{
    margin:0;
    color:#666;
    font-size:.78rem;
    line-height:1.75;
}
.cms-home-sitemap-books{
    gap:14px;
}
.cms-home-sitemap-books article{
    position:relative;
    min-height:330px;
    padding:20px 18px 18px;
    overflow:hidden;
    border:1px solid #8f8f8f;
    border-radius:2px 10px 10px 2px;
    background:
        linear-gradient(90deg,#ececec 0,#f7f7f7 13px,#fbfbfb 13px,#fbfbfb 100%);
    box-shadow:inset 3px 0 0 #d7d7d7;
}
.cms-home-sitemap-books article::after{
    content:"";
    position:absolute;
    left:13px;
    right:0;
    bottom:0;
    height:5px;
    border-top:1px solid #d1d1d1;
    background:repeating-linear-gradient(0deg,#f6f6f6 0 1px,#e8e8e8 1px 2px);
}
.cms-sitemap-number{
    position:absolute;
    top:14px;
    right:14px;
    color:#b5b5b5;
    font-size:1.65rem;
    font-weight:800;
    letter-spacing:-.05em;
}
.cms-home-sitemap-books h3{
    margin:3px 0 18px;
    font-size:1.05rem;
    letter-spacing:.04em;
}
.cms-home-sitemap-books article>a{
    position:relative;
    padding:11px 18px 11px 0;
    border-top:1px solid #d3d3d3;
}
.cms-home-sitemap-books article>a::after{
    content:"›";
    position:absolute;
    right:2px;
    top:50%;
    transform:translateY(-50%);
    color:#888;
    font-size:1rem;
}
.cms-home-sitemap-books article>a:hover{
    padding-left:4px;
}
.cms-home-sitemap-books article>a:hover strong{
    text-decoration:none;
}
.cms-home-private-note{
    display:grid;
    grid-template-columns:150px 1fr;
    gap:16px;
    margin-top:14px;
    padding:13px 16px;
    border-left:3px solid #777;
    background:#ececec;
}
.cms-home-private-note span{
    font-size:10px;
    font-weight:800;
    letter-spacing:.12em;
}
.cms-home-private-note p{
    margin:0;
    color:#5f5f5f;
    font-size:.74rem;
    line-height:1.75;
}
@media(max-width:720px){
    .cms-home-sitemap-title,
    .cms-home-private-note{
        grid-template-columns:1fr;
    }
    .cms-home-sitemap-books article{
        min-height:0;
    }
}
