/*
Theme Name: Nacolle Team
Theme URI: https://team.nacolle.com/
Author: 椿ヨナ
Description: nacolle チームサイト用テーマ（3人・形混在レイアウト版）
Version: 2.0.0
License: GNU General Public License v2 or later
Text Domain: nacolle
*/

:root {
  --color-main: #48C9C2;
  --color-main-dark: #2BA8A1;
  --color-bg: #FBF8F0;
  --color-hero-bg: #F0FAFA;
  --color-salmon: #E8837C;
  --color-orange: #FFB347;
  --color-coral: #F5A4A4;
  --color-lavender: #C39BD3;
  --color-skyblue: #85C1E9;
  --color-text: #222222;
  --color-text-muted: #888888;
  --color-white: #ffffff;
  --font-main: 'Hiragino Kaku Gothic ProN', 'Yu Gothic UI', 'Noto Sans JP', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; }

/* ===== チーム背景：黒基調 + 形レイヤー（最小導入） ===== */
html, body { min-height: 100dvh; }
body.nacolle-dark { background: #1E1E22; color: #EDEDED; display: flex; flex-direction: column; }
.bg-shapes { position: fixed; top: 70px; height: calc(100dvh - 70px); left: 50%; transform: translateX(-50%); width: 1760px; z-index: 0; pointer-events: none; }
.bg-shape { position: absolute; opacity: 0.45; }
.bg-shape svg { display: block; width: 100%; height: 100%; overflow: visible; }
/* ヘッダー・フッターを形より前面に（対でセット） */
.site-header { z-index: 100; }
.site-footer { position: relative; z-index: 5; }
/* コンテンツを形より前面に */
.team-layout, .content-area, .hero { position: relative; z-index: 1; }
/* スティッキーフッター用にコンテンツを伸ばす */
.team-layout { flex: 1 0 auto; }
/* 白背景コンテナの中の文字は濃い色に戻す（黒基調で薄くなる対策） */
.post-single, .page-content, .sidebar-widget, .grid-card, .nav-prev, .nav-next {
	color: var(--color-text);
}
.post-single :where(h1,h2,h3,h4,h5,h6,p,li,span,td,th,a,time,div),
.page-content :where(h1,h2,h3,h4,h5,h6,p,li,span,td,th,time,div),
.sidebar-widget :where(p,li,span,a,time),
.grid-card :where(h1,h2,h3,h4,h5,h6,p,li,span,time) {
	color: var(--color-text);
}
/* リンクやカテゴリラベル等、元から色が付く要素は維持 */
.sidebar-widget .sidebar-widget-title, .sidebar-widget .members-heading { color: var(--color-main); }
/* 色付き背景の白文字ラベルは白を維持（広い文字色指定から保護） */
.post-single-category, .post-card-category, .badge-new, .section-label, .hero-badge, .more-button {
	color: var(--color-white);
}
/* サイドバーのカテゴリーリンクは元のティール維持 */
.widget-categories li a { color: var(--color-main); }
body { font-family: var(--font-main); background: var(--color-bg); color: var(--color-text); line-height: 1.7; overflow-x: hidden; }
a { color: var(--color-main); text-decoration: none; }
a:hover { opacity: 0.8; }
img { max-width: 100%; height: auto; display: block; }

/* Header */
.site-header { background: var(--color-main); padding: 0 2rem; height: 70px; display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 100; }
.site-logo img { height: 52px; width: auto; }
.site-logo a { display: block; font-size: 1.4rem; font-weight: 700; color: var(--color-white); }
.main-navigation ul { display: flex; gap: 1.8rem; list-style: none; }
.main-navigation a { font-size: 0.8rem; color: rgba(255,255,255,0.85); font-weight: 700; }
.main-navigation a:hover, .main-navigation .current-menu-item a { color: var(--color-white); opacity: 1; }
.menu-toggle { display: none; background: none; border: none; cursor: pointer; padding: 0.5rem; }
.menu-toggle span { display: block; width: 24px; height: 2px; background: var(--color-white); margin: 5px 0; }

/* Hero */
.site-hero { background: var(--color-hero-bg); border-bottom: 4px solid var(--color-main); padding: 1rem 2rem; display: flex; align-items: center; gap: 1rem; }
.hero-badge { background: var(--color-salmon); color: var(--color-white); font-size: 0.7rem; font-weight: 700; padding: 5px 16px; border-radius: 18px 10px 20px 11px / 11px 19px 10px 18px; white-space: nowrap; flex-shrink: 0; }
.hero-text { font-size: 0.85rem; color: #555; }

/* Layout */
.content-area { flex: 1 0 auto; width: 100%; max-width: 960px; margin: 0 auto; padding: 2rem 1.5rem; display: grid; grid-template-columns: 1fr 230px; gap: 2rem; align-items: start; }
.site-main { min-width: 0; }
.section-label { font-size: 0.7rem; font-weight: 700; color: var(--color-white); background: var(--color-main); display: inline-block; padding: 4px 16px; border-radius: 14px 7px 16px 8px / 8px 15px 7px 14px; margin-bottom: 1rem; letter-spacing: 2px; }

/* 円形カード */
.cards-wrap { position: relative; width: 100%; height: 820px; overflow: visible; }
.post-card { position: absolute; border-radius: 50%; overflow: hidden; border: 4px solid var(--color-main); box-shadow: 7px 7px 0 var(--color-main); display: flex; flex-direction: column; align-items: center; justify-content: flex-start; cursor: pointer; background: #ececec; text-decoration: none; transition: border-radius 0.35s ease; }
.post-card:hover { border-radius: 62% 38% 55% 45% / 48% 58% 42% 52%; }
.post-card:nth-child(1):hover { border-radius: 58% 42% 60% 40% / 52% 45% 55% 48%; }
.post-card:nth-child(2):hover { border-radius: 40% 60% 45% 55% / 60% 40% 58% 42%; }
.post-card:nth-child(3):hover { border-radius: 65% 35% 50% 50% / 45% 60% 40% 55%; }
.post-card:nth-child(4):hover { border-radius: 50% 50% 38% 62% / 58% 42% 55% 45%; }
.post-card:nth-child(5):hover { border-radius: 45% 55% 62% 38% / 50% 55% 45% 50%; }
.post-card:nth-child(6):hover { border-radius: 60% 40% 48% 52% / 42% 58% 50% 48%; }
.post-card.cat-movie  { border-color: var(--color-lavender); box-shadow: 7px 7px 0 var(--color-lavender); }
.post-card.cat-drama  { border-color: var(--color-salmon);   box-shadow: 7px 7px 0 var(--color-salmon); }
.post-card.cat-essay, .post-card.cat-zakki { border-color: var(--color-orange); box-shadow: 7px 7px 0 var(--color-orange); }
.post-card.cat-outing { border-color: var(--color-skyblue);  box-shadow: 7px 7px 0 var(--color-skyblue); }

.post-card:nth-child(1) { width: 340px; height: 340px; left: 0px;   top: 10px;  }
.post-card:nth-child(2) { width: 210px; height: 210px; left: 400px; top: 0px;   }
.post-card:nth-child(3) { width: 300px; height: 300px; left: 200px; top: 180px; }
.post-card:nth-child(4) { width: 230px; height: 230px; left: 10px;  top: 450px; }
.post-card:nth-child(5) { width: 340px; height: 340px; left: 290px; top: 430px; }
.post-card:nth-child(6) { width: 240px; height: 240px; left: 120px; top: 570px; }

/* 通常時から歪んだ有機的な円 */
.post-card:nth-child(1) { border-radius: 54% 46% 52% 48% / 48% 52% 48% 52%; }
.post-card:nth-child(2) { border-radius: 48% 52% 46% 54% / 52% 46% 54% 48%; }
.post-card:nth-child(3) { border-radius: 52% 48% 50% 50% / 46% 54% 46% 54%; }
.post-card:nth-child(4) { border-radius: 46% 54% 52% 48% / 54% 46% 50% 50%; }
.post-card:nth-child(5) { border-radius: 50% 50% 46% 54% / 50% 50% 54% 46%; }
.post-card:nth-child(6) { border-radius: 53% 47% 48% 52% / 47% 53% 52% 48%; }


.post-card-overlay { width: 100%; background: rgba(255,255,255,0.92); padding: 18px 22% 10px; display: flex; flex-direction: column; align-items: center; gap: 4px; flex-shrink: 0; }
.post-card-category { font-size: 0.62rem; font-weight: 700; color: var(--color-white); background: var(--color-main); border-radius: 10px 5px 12px 6px / 6px 11px 5px 10px; padding: 2px 10px; display: inline-block; }
.post-card-category.cat-movie  { background: var(--color-lavender); }
.post-card-category.cat-drama  { background: var(--color-salmon); }
.post-card-category.cat-essay, .post-card-category.cat-zakki { background: var(--color-orange); }
.post-card-category.cat-outing { background: var(--color-skyblue); }
.post-card-category.cat-about  { background: var(--color-main); }
.post-card-title { font-size: 0.68rem; font-weight: 700; color: var(--color-text); line-height: 1.5; text-align: center; }
.badge-new { background: var(--color-salmon); color: var(--color-white); font-size: 0.5rem; font-weight: 700; padding: 1px 4px; border-radius: 2px; margin-left: 3px; vertical-align: middle; }
.post-card-img { flex: 1; width: 100%; background-size: cover; background-position: top center; background-color: #e8e8e8; display: flex; align-items: center; justify-content: center; font-size: 3rem; }
.sp-only-img { display: none; }
.post-card-img .no-thumb { opacity: 0.25; }

.more-wrap { display: flex; justify-content: center; margin-top: 1.5rem; }
.more-button { display: inline-block; background: var(--color-main); color: var(--color-white); font-size: 0.85rem; font-weight: 700; text-decoration: none; padding: 16px 40px; border: 4px solid var(--color-main-dark); border-radius: 70% 30% 65% 35% / 40% 60% 35% 60%; box-shadow: 5px 5px 0 var(--color-main-dark); transition: transform 0.1s, box-shadow 0.1s, border-radius 0.2s; }
.more-button:hover { transform: translate(2px,2px); box-shadow: 3px 3px 0 var(--color-main-dark); border-radius: 35% 65% 40% 60% / 60% 35% 65% 40%; opacity: 1; }

/* Pagination */
.posts-pagination { margin-top: 2rem; display: flex; gap: 0.5rem; justify-content: center; flex-wrap: wrap; }
.posts-pagination .page-numbers { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border: 3px solid var(--color-main); border-radius: 6px; font-size: 0.8rem; font-weight: 700; color: var(--color-main); background: var(--color-white); box-shadow: 3px 3px 0 var(--color-main); }
.posts-pagination .page-numbers.current, .posts-pagination .page-numbers:hover { background: var(--color-main); color: var(--color-white); }

/* アーカイブ用 四角カードグリッド */
.posts-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.grid-card { background: var(--color-white); border: 4px solid var(--color-main); border-radius: 12px; overflow: hidden; box-shadow: 5px 5px 0 var(--color-main); display: flex; flex-direction: column; transition: border-radius 0.3s ease; }
.grid-card:hover { border-radius: 30px 12px 30px 12px; }
.grid-card.cat-movie  { border-color: var(--color-lavender); box-shadow: 5px 5px 0 var(--color-lavender); }
.grid-card.cat-drama  { border-color: var(--color-salmon);   box-shadow: 5px 5px 0 var(--color-salmon); }
.grid-card.cat-essay, .grid-card.cat-zakki { border-color: var(--color-orange); box-shadow: 5px 5px 0 var(--color-orange); }
.grid-card.cat-outing { border-color: var(--color-skyblue);  box-shadow: 5px 5px 0 var(--color-skyblue); }
.grid-card-thumb { width: 100%; position: relative; padding-bottom: 100%; overflow: hidden; background: #f0f0f0; }
.grid-card-thumb a { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
.grid-card-thumb .no-thumb { position: absolute; top: 0; left: 0; width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 2rem; }
.grid-card-body { padding: 12px 14px; flex: 1; display: flex; flex-direction: column; }
.grid-card-body .post-card-category { align-self: flex-start; margin-bottom: 6px; }
.grid-card-title { font-size: 0.875rem; font-weight: 700; line-height: 1.5; margin-bottom: 6px; flex: 1; }
.grid-card-title a { color: var(--color-text); }
.grid-card-date { font-size: 0.7rem; color: var(--color-text-muted); }

/* Sidebar */
.sidebar { display: flex; flex-direction: column; gap: 1.5rem; padding-top: 2.25rem; position: relative; z-index: 10; }
.profile-circle { width: 220px; height: 220px; min-width: 220px; min-height: 220px; flex-shrink: 0; box-sizing: border-box; border-radius: 56% 44% 52% 48% / 50% 54% 46% 50%; background: var(--color-main); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 1rem 1.8rem 1.8rem; border: 4px solid var(--color-coral); box-shadow: 5px 5px 0 var(--color-coral); margin: 0 auto; overflow: hidden; transition: border-radius 0.35s ease; }
.profile-circle:hover { border-radius: 58% 42% 55% 45% / 50% 55% 45% 52%; }
.profile-avatar { width: 56px !important; height: 0 !important; padding-bottom: 56px !important; border-radius: 50% !important; background-size: cover !important; background-position: center top !important; background-repeat: no-repeat !important; margin: 0 auto 6px !important; border: 2px solid rgba(255,255,255,0.5) !important; overflow: hidden !important; position: relative !important; display: block !important; }
.profile-avatar img { display: none !important; }
.profile-avatar-placeholder { width: 44px; height: 44px; border-radius: 50%; background: var(--color-white); margin: 0 auto 6px; display: flex; align-items: center; justify-content: center; font-size: 1rem; font-weight: 700; color: var(--color-main); border: 2px solid rgba(255,255,255,0.5); }
.profile-name { font-size: 14px; font-weight: 700; color: var(--color-white); margin-bottom: 2px; }
.profile-handle { font-size: 10px; color: rgba(255,255,255,0.85); margin-bottom: 8px; }
.profile-bio { font-size: 9px; color: rgba(255,255,255,0.9); line-height: 1.55; }
.profile-handle a { color: rgba(255,255,255,0.85); }

.sidebar-widget { background: var(--color-white); border: 4px solid var(--color-main); padding: 1rem; box-shadow: 5px 5px 0 var(--color-main); border-radius: 24px 14px 28px 16px / 16px 26px 14px 24px; transition: border-radius 0.35s ease; }
.sidebar-widget:nth-child(odd) { border-radius: 14px 26px 16px 24px / 26px 14px 24px 16px; }
.sidebar-widget:nth-child(3n) { border-radius: 18px 24px 16px 22px / 24px 16px 22px 18px; }
.sidebar-widget:hover { border-radius: 55px 18px 60px 20px / 22px 58px 18px 52px; }
.sidebar-widget-title { font-size: 0.65rem; font-weight: 700; color: var(--color-main); letter-spacing: 1.5px; margin-bottom: 8px; }
.widget-categories ul { list-style: none; display: flex; flex-wrap: wrap; gap: 5px; padding: 0; }
.widget-categories li a { display: inline-block; background: var(--color-hero-bg); border: 2px solid var(--color-main); border-radius: 12px 6px 14px 7px / 7px 13px 6px 12px; font-size: 0.65rem; font-weight: 700; color: var(--color-main); padding: 2px 10px; }
.widget-categories li a:hover { background: var(--color-main); color: var(--color-white); opacity: 1; }
.sidebar-widget ul { list-style: none; padding: 0; }
.sidebar-widget li { margin-bottom: 4px; }
.sidebar-widget li a { font-size: 0.7rem; color: var(--color-text); }

/* Single / Page */
.post-single, .page-content { background: var(--color-white); border: 4px solid var(--color-main); border-radius: 12px; box-shadow: 5px 5px 0 var(--color-main); overflow: hidden; }
.post-single-thumbnail img { width: 100%; max-height: 400px; object-fit: cover; object-position: right top; display: block; }
.post-single-header { padding: 1.5rem 1.5rem 0; }
.post-single-content { padding: 1.5rem; }
.page-content { padding: 2rem; }
.post-single-category { font-size: 0.65rem; font-weight: 700; color: var(--color-white); background: var(--color-main); border-radius: 4px; padding: 2px 8px; display: inline-block; margin-bottom: 8px; }
.post-single-title, .page-title { font-size: 1.3rem; font-weight: 700; line-height: 1.5; margin-bottom: 8px; }
.page-title { padding-bottom: 0.75rem; border-bottom: 3px solid var(--color-main); margin-bottom: 1.5rem; }
.post-single-meta { font-size: 0.75rem; color: var(--color-text-muted); margin-bottom: 1rem; }
.post-single-content p, .page-content p { margin-bottom: 1.2rem; font-size: 0.95rem; line-height: 1.8; }
.post-single-content h2 { font-size: 1.1rem; font-weight: 700; margin: 1.5rem 0 0.75rem; padding-left: 0.75rem; border-left: 4px solid var(--color-main); }
.post-single-content img { border-radius: 8px; margin: 1rem 0; }
.post-single-content ul, .post-single-content ol { padding-left: 1.5rem; margin-bottom: 1rem; }

.post-navigation { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 2rem; }
.nav-prev, .nav-next { background: var(--color-white); border: 3px solid var(--color-main); border-radius: 8px; padding: 0.75rem 1rem; box-shadow: 3px 3px 0 var(--color-main); font-size: 0.8rem; color: var(--color-text); }
.nav-next { text-align: right; }
.nav-label { font-size: 0.65rem; color: var(--color-main); font-weight: 700; display: block; margin-bottom: 3px; }

/* Footer */
.site-footer { background: var(--color-main); border-top: 4px solid var(--color-main-dark); padding: 1.25rem 2rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.footer-logo img { height: 36px; width: auto; }
.footer-logo a { font-size: 1rem; font-weight: 700; color: var(--color-white); }
.footer-nav ul { display: flex; gap: 1.5rem; list-style: none; }
.footer-nav a { font-size: 0.7rem; color: rgba(255,255,255,0.85); font-weight: 700; }
.footer-copy { font-size: 0.7rem; color: rgba(255,255,255,0.65); }

/* Responsive */
@media (max-width: 900px) {
  .content-area { grid-template-columns: 1fr; padding: 1.5rem 1.25rem; }
  .sidebar { display: contents; }
  .profile-circle { order: -1; width: 140px; height: 140px; padding: 1rem; margin: 1rem auto 0; }
  .profile-bio { display: none; }
  .profile-avatar { width: 48px !important; padding-bottom: 48px !important; }
  .profile-handle { margin-bottom: 0; }
  .sidebar-widget { order: 2; }
  .cards-wrap { height: auto; overflow: visible; }
  .post-card { position: static; width: 100% !important; height: auto !important; border-radius: 16px !important; flex-direction: column; margin-bottom: 1.25rem; justify-content: flex-start; overflow: hidden; box-shadow: 5px 5px 0 var(--color-main); }
  .post-card:hover { border-radius: 16px !important; }
  .post-card.cat-movie  { box-shadow: 5px 5px 0 var(--color-lavender); }
  .post-card.cat-drama  { box-shadow: 5px 5px 0 var(--color-salmon); }
  .post-card.cat-essay, .post-card.cat-zakki { box-shadow: 5px 5px 0 var(--color-orange); }
  .post-card.cat-outing { box-shadow: 5px 5px 0 var(--color-skyblue); }
  /* 生成済みサムネは正方形。画像を正方形で表示し、下にタイトル */
  .post-card-img { order: 1; width: 100%; height: 0; padding-bottom: 100%; min-width: 0; background-size: cover; background-position: center; font-size: 0; }
  .post-card-overlay { order: 2; width: 100%; min-width: 0; max-width: none; height: auto; padding: 14px 16px 16px; justify-content: flex-start; align-items: flex-start; border-radius: 0; background: #fff; flex-shrink: 0; }
  .post-card-title { font-size: 0.92rem; text-align: left; }
  .posts-grid { grid-template-columns: 1fr; }
  .site-header { padding: 0 1rem; }
  .main-navigation { display: none; position: absolute; top: 70px; left: 0; right: 0; background: var(--color-main-dark); padding: 1rem; z-index: 99; }
  .main-navigation.is-open { display: block; }
  .main-navigation ul { flex-direction: column; gap: 0; }
  .main-navigation a { display: block; padding: 0.75rem 1rem; border-bottom: 1px solid rgba(255,255,255,0.2); }
  .menu-toggle { display: block; }
  .site-hero { padding: 1rem; flex-direction: column; align-items: flex-start; }
  .site-footer { flex-direction: column; text-align: center; gap: 0.75rem; }
  .post-navigation { grid-template-columns: 1fr; }
}


/* ===========================
   一覧ページ 歪み円グリッド
=========================== */
.circle-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 2rem 1.5rem; align-items: center; justify-items: center; }
.ccard { display: flex; flex-direction: column; align-items: center; text-decoration: none; width: 100%; }
.ccard-circle {
  overflow: hidden; position: relative;
  border: 4px solid var(--color-main); box-shadow: 5px 5px 0 var(--color-main);
  background: #ececec;
  transition: border-radius 0.35s ease;
}
.ccard.cat-movie .ccard-circle { border-color: var(--color-lavender); box-shadow: 5px 5px 0 var(--color-lavender); }
.ccard.cat-drama .ccard-circle { border-color: var(--color-salmon); box-shadow: 5px 5px 0 var(--color-salmon); }
.ccard.cat-essay .ccard-circle, .ccard.cat-zakki .ccard-circle { border-color: var(--color-orange); box-shadow: 5px 5px 0 var(--color-orange); }
.ccard.cat-outing .ccard-circle { border-color: var(--color-skyblue); box-shadow: 5px 5px 0 var(--color-skyblue); }

/* サイズを6パターンでばらつかせる */
.ccard:nth-child(6n+1) .ccard-circle { width: 100%; padding-bottom: 100%; }
.ccard:nth-child(6n+2) .ccard-circle { width: 78%;  padding-bottom: 78%; }
.ccard:nth-child(6n+3) .ccard-circle { width: 90%;  padding-bottom: 90%; }
.ccard:nth-child(6n+4) .ccard-circle { width: 82%;  padding-bottom: 82%; }
.ccard:nth-child(6n+5) .ccard-circle { width: 100%; padding-bottom: 100%; }
.ccard:nth-child(6n+6) .ccard-circle { width: 86%;  padding-bottom: 86%; }

/* 通常時から歪んだ円 */
.ccard:nth-child(6n+1) .ccard-circle { border-radius: 54% 46% 52% 48% / 48% 52% 48% 52%; }
.ccard:nth-child(6n+2) .ccard-circle { border-radius: 48% 52% 46% 54% / 52% 46% 54% 48%; }
.ccard:nth-child(6n+3) .ccard-circle { border-radius: 52% 48% 50% 50% / 46% 54% 46% 54%; }
.ccard:nth-child(6n+4) .ccard-circle { border-radius: 46% 54% 52% 48% / 54% 46% 50% 50%; }
.ccard:nth-child(6n+5) .ccard-circle { border-radius: 50% 50% 46% 54% / 50% 50% 54% 46%; }
.ccard:nth-child(6n+6) .ccard-circle { border-radius: 53% 47% 48% 52% / 47% 53% 52% 48%; }
.ccard:hover .ccard-circle { border-radius: 65% 35% 58% 42% / 45% 60% 40% 55% !important; }

.ccard-overlay { position: absolute; bottom: 0; left: 0; width: 100%; background: rgba(255,255,255,0.92); padding: 8px 16% 14px; display: flex; flex-direction: column; align-items: center; gap: 3px; z-index: 2; }
.ccard-title { font-size: 0.66rem; font-weight: 700; color: var(--color-text); line-height: 1.4; text-align: center; }
.ccard-img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-size: cover; background-position: top center; display: flex; align-items: flex-start; justify-content: center; padding-top: 12%; font-size: 1.6rem; z-index: 1; }
.ccard-img .no-thumb { opacity: 0.3; }
.ccard-date { font-size: 0.6rem; color: var(--color-text-muted); margin-top: 8px; text-align: center; }

@media (max-width: 900px) {
  .circle-grid { grid-template-columns: 1fr 1fr; }
  .ccard-circle { width: 100% !important; padding-bottom: 100% !important; }
}

/* ============================================================
   チームサイト：3人・形混在トップ
============================================================ */
.cards-wrap { position: relative; width: 720px; max-width: 100%; margin: 0; height: 840px; }
.mcard { position: absolute; text-decoration: none; transition: transform 0.25s ease; }
.mcard:hover { transform: scale(1.04) rotate(-1.5deg); z-index: 99 !important; opacity: 1; }
.svg-card svg { display: block; width: 100%; height: 100%; overflow: visible; }
.svg-card .title-bar { fill: #ffffff; fill-opacity: 0.94; transition: fill-opacity 0.25s ease; }
.mcard.svg-card:hover .title-bar,
.mcard-grid.svg-card:hover .title-bar { fill-opacity: 1; }
.mcard .label { position: absolute; left: 50%; top: 17%; transform: translateX(-50%); text-align: center; width: 64%; }
.cat-tag { font-size: 0.6rem; font-weight: 700; color: #fff; border-radius: 10px 5px 12px 6px / 6px 11px 5px 10px; padding: 2px 9px; display: inline-block; }
.ctitle { font-size: 0.62rem; font-weight: 700; color: #222; line-height: 1.4; margin: 3px 0 2px; }
.by { font-size: 0.54rem; font-weight: 700; }
/* SVGカード（五角形・葉）は白帯が固定サイズなので、長いタイトルははみ出す。行数を制限して帯内に収める（円カードは帯が伸びるので対象外） */
.svg-label .ctitle { display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* 椿ヨナの円（CSS border-radius・本体サイトと同方式） */
.yona-circle { overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; background: #ececec; transition: transform 0.25s ease, border-radius 0.35s ease; }
.yona-circle:hover { border-radius: 58% 42% 60% 40% / 52% 45% 55% 48% !important; }
.yc-overlay { width: 100%; background: rgba(255,255,255,0.94); padding: 14px 16% 8px; box-sizing: border-box; text-align: center; transition: background 0.25s ease; }
.yona-circle:hover .yc-overlay { background: #ffffff; }
.yc-overlay .label-inner { display: block; }
.yc-img { flex: 1; width: 100%; display: flex; align-items: center; justify-content: center; font-size: 2rem; opacity: 0.4; background-size: cover; background-position: center; }

/* スマホ：トップは本体踏襲の横長長方形カード（テキスト左／各自の形サムネ右） */
@media (max-width: 900px) {
  .cards-wrap { height: auto; width: 100%; display: flex; flex-direction: column; align-items: stretch; gap: 1rem; }

  /* 横長長方形カード本体（.mcard はトップ専用。メンバーは .mcard-grid なので無関係） */
  .mcard { position: static !important; width: 100% !important; max-width: none !important; height: auto !important;
           aspect-ratio: auto !important; display: flex; flex-direction: row; align-items: center; gap: 12px;
           padding: 14px; background: #fff; border: none !important; border-radius: 18px !important;
           box-shadow: 5px 5px 0 var(--cat, #48C9C2) !important; overflow: visible; }
  .mcard:hover { transform: none; border-radius: 18px !important; }

  /* テキスト左（円=yc-overlay / SVG=svg-label の両方） */
  .mcard .yc-overlay, .mcard .svg-label { position: static !important; order: 1; flex: 1 1 auto; min-width: 0;
      width: auto !important; transform: none !important; left: auto !important; top: auto !important;
      background: transparent !important; padding: 0 !important; text-align: left !important; }
  .mcard .yc-overlay .label-inner { text-align: left; }
  .mcard .cat-tag { display: inline-block; margin-bottom: 6px; }
  .mcard .ctitle { font-size: 0.95rem; line-height: 1.5; text-align: left; margin: 0 0 6px;
      display: block; -webkit-line-clamp: unset; line-clamp: unset; }
  .mcard .by { display: block; }

  /* 右に各自の形サムネ（92px・カテゴリー色のフチ） */
  .mcard.yona-circle .yc-img { order: 2; flex: none; width: 92px; height: 92px; min-width: 92px; align-self: center;
      border: 3px solid var(--cat, #48C9C2); border-radius: 54% 46% 52% 48% / 48% 52% 48% 52%;
      overflow: hidden; opacity: 1; font-size: 1.6rem; }
  .mcard.svg-card svg { order: 2; flex: none; width: 92px !important; height: 92px !important; min-width: 92px; align-self: center; filter: none !important; }
  .mcard.svg-card .title-bar { display: none; } /* テキストは外（左）に出すので白帯は不要 */
  .mcard.empty-card { display: none; } /* 記事が足りない空き枠はスマホでは出さない（本体のリストに合わせる） */

  /* メンバーページの円カード（mobile）は従来どおりの大きさを維持 */
  .mcard-grid.yona-circle { width: 80% !important; max-width: 320px; aspect-ratio: 1 / 1; height: auto !important; }
}

/* チームトップ：モックアップ準拠レイアウト */
.hero { background: #F0FAFA; border-bottom: 4px solid #48C9C2; padding: 1rem 2rem; }
.hero-text { font-size: 0.85rem; color: #555; margin: 0 0 0.6rem; }
.legend { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.legend-item { display: flex; align-items: center; gap: 6px; font-size: 0.72rem; font-weight: 700; color: #555; }

.team-layout { max-width: 1100px; margin: 0 auto; padding: 2rem 2.5rem; display: grid; grid-template-columns: 720px 230px; gap: 2.5rem; align-items: start; justify-content: center; }
.team-layout .site-main { min-width: 0; }
.team-sidebar { padding-top: 2.25rem; }

@media (max-width: 900px) {
  /* スマホ：メンバー一覧を一番上に（本体のprofile order:-1 と同じ）。
     並び＝メンバー一覧 → LATEST（カード） → カテゴリー/アーカイブ
     ※サイドバーは .team-sidebar > .sidebar の二重なので両方 display:contents で平坦化しないと order が効かない */
  .team-layout { grid-template-columns: 1fr; width: 100%; gap: 1.5rem; padding: 1.5rem 1.25rem; }
  .team-sidebar, .team-sidebar .sidebar { display: contents; }
  .team-sidebar .members-block { order: -1; }
  .team-sidebar .sidebar-widget:not(.members-block) { order: 2; }
}

/* ============================================================
   メンバーページ（投稿者アーカイブ）
============================================================ */
.member-page { width: 100%; flex: 1 0 auto; max-width: 880px; margin: 0 auto; padding: 2.5rem 1.5rem 2rem; }
.member-hero { display: flex; align-items: center; gap: 1.5rem; margin-bottom: 2rem; }
.member-avatar { width: 120px; height: 120px; flex-shrink: 0; }
.member-avatar.circle { border: 5px solid; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.member-avatar.circle img { width: 100%; height: 100%; object-fit: cover; }
.member-avatar.svg svg { display: block; width: 100%; height: 100%; overflow: visible; }
.member-name { font-size: 1.5rem; font-weight: 700; margin: 0 0 2px; }
.member-handle { font-size: 0.85rem; font-weight: 700; margin: 0 0 8px; }
.member-bio { font-size: 0.85rem; color: #666; margin: 0; line-height: 1.7; }

.member-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem 0; margin-top: 1.5rem; justify-items: center; align-items: start; }
.mcard-grid { position: relative; width: 100%; max-width: 340px; aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; text-decoration: none; transition: transform 0.25s ease; }
.mcard-grid.svg-card { aspect-ratio: 1 / 1; }
/* 円カード：本体(.ccard > .ccard-circle)と同じ入れ子。正方形は内側の .yc-circle が padding-bottom で確定（グリッドアイテム自身には掛けない） */
.member-cards .mcard-grid.yona-circle { display: flex; align-items: center; justify-content: center; overflow: visible; background: transparent; }
.member-cards .yc-circle { position: relative; width: 76%; height: 76%; padding-bottom: 0; overflow: hidden; background: #ececec; }
.member-cards .yc-circle .yc-overlay { position: absolute; top: 0; left: 0; width: 100%; z-index: 2; }
.member-cards .yc-circle .yc-img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; }
.member-cards .yona-circle:hover .yc-circle { border-radius: 58% 42% 60% 40% / 52% 45% 55% 48% !important; }
.mcard-grid:hover { transform: scale(1.04) rotate(-1.5deg); z-index: 2; opacity: 1; }
.mcard-grid.svg-card svg { display: block; width: 100%; height: 100%; overflow: visible; }
.mcard-grid.svg-card.pentagon svg { width: 94%; height: 94%; }
.mcard-grid .label { position: absolute; left: 50%; top: 17%; transform: translateX(-50%); text-align: center; width: 64%; }

@media (max-width: 900px) {
  .member-cards { grid-template-columns: repeat(2, 1fr); column-gap: 1rem; }
  .member-hero { flex-direction: column; text-align: center; }
}
@media (max-width: 560px) {
  .member-cards { grid-template-columns: 1fr; }
}

/* 記事が足りない枠：白い空枠 */
.empty-card { position: absolute; }
.empty-card.svg-card svg { display: block; width: 100%; height: 100%; overflow: visible; }

/* ============================================================
   サイドバー：3人メンバー紹介
============================================================ */
.team-members-sidebar { display: flex; flex-direction: column; gap: 1.5rem; padding-top: 2.25rem; }
.members-block { display: flex; flex-direction: column; }
.members-heading { font-size: 0.65rem; font-weight: 700; color: var(--color-main); letter-spacing: 1.5px; margin-bottom: 0.75rem; }
.members-list { display: flex; flex-direction: column; gap: 1.25rem; }

.member-mini { display: flex; align-items: center; gap: 0.85rem; text-decoration: none; }
.member-mini-shape { flex-shrink: 0; width: 79px; height: 79px; display: flex; align-items: center; justify-content: center; overflow: visible; }
.member-mini-disc { width: 60px; height: 60px; display: flex; align-items: center; justify-content: center; overflow: hidden; transition: transform 0.25s ease, border-radius 0.35s ease; }
.member-mini-svg { display: block; transition: transform 0.25s ease; }
.member-mini-svg.pentagon { width: 74px; height: 74px; }
.member-mini-svg.leaf { width: 79px; height: 79px; }
.member-mini-svg svg { display: block; width: 100%; height: 100%; overflow: visible; }
.member-mini:hover .member-mini-disc { border-radius: 62% 38% 55% 45% / 48% 58% 42% 52% !important; }
.member-mini:hover .member-mini-svg { transform: scale(1.05) rotate(-2deg); }
.member-mini-initial { font-size: 1.4rem; font-weight: 700; color: var(--color-white); }

.member-mini-info { display: flex; flex-direction: column; min-width: 0; }
.member-mini-name { font-size: 0.85rem; font-weight: 700; color: var(--color-text); }
.member-mini-handle { font-size: 0.62rem; font-weight: 700; margin-top: 1px; }
.member-mini-bio { font-size: 0.6rem; color: var(--color-text-muted); line-height: 1.5; margin-top: 4px; }

@media (max-width: 900px) {
  .team-members-sidebar { padding-top: 0; }
  .members-heading { text-align: center; }
  .members-list { flex-direction: row; flex-wrap: wrap; gap: 1rem; justify-content: center; }
  .member-mini { flex-direction: column; text-align: center; gap: 0.4rem; width: 28%; }
  .member-mini-shape { width: 64px; height: 64px; }
  .member-mini-disc { width: 49px; height: 49px; }
  .member-mini-svg.pentagon { width: 60px; height: 60px; }
  .member-mini-svg.leaf { width: 64px; height: 64px; }
  .member-mini-bio { display: none; }
}

/* 個別投稿ページの投稿者プロフィール（本体profile-circleと同じ作り） */
.profile-circle { width: 220px; height: 220px; min-width: 220px; min-height: 220px; box-sizing: border-box; border-radius: 56% 44% 52% 48% / 50% 54% 46% 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 1rem 1.8rem 1.8rem; border: 4px solid; margin: 0 auto 1.2rem; overflow: hidden; }
.profile-circle .profile-avatar { width: 56px; height: 0; padding-bottom: 56px; border-radius: 50%; background-size: cover; background-position: center top; background-repeat: no-repeat; margin: 0 auto 6px; border: 2px solid rgba(255,255,255,0.5); overflow: hidden; display: block; }
.profile-circle .profile-avatar-shape { width: 60px; height: 60px; margin: 0 auto 6px; }
.profile-circle .profile-avatar-shape svg { display: block; width: 100%; height: 100%; overflow: visible; }
.profile-circle .profile-name { font-size: 14px; font-weight: 700; color: #fff; margin-bottom: 2px; }
.profile-circle .profile-handle { font-size: 10px; color: rgba(255,255,255,0.85); margin-bottom: 8px; }
.profile-circle .profile-handle a { color: rgba(255,255,255,0.85); }
.profile-circle .profile-bio { font-size: 9px; color: rgba(255,255,255,0.92); line-height: 1.55; }

/* 記事下：投稿者の投稿一覧ボタン */
.author-archive-link { text-align: center; margin: 1.5rem 0 0.5rem; }
.author-archive-button { display: inline-block; padding: 0.7rem 1.8rem; font-size: 0.9rem; font-weight: 700; color: #fff; background: var(--color-main); border-radius: 14px 8px 16px 10px / 10px 14px 8px 16px; box-shadow: 4px 4px 0 rgba(0,0,0,0.15); text-decoration: none; transition: transform 0.15s ease; }
.author-archive-button:hover { transform: translate(-1px,-1px); }
/* 前/次ナビの投稿者名 */
.post-navigation .nav-label { display: block; font-size: 0.72rem; opacity: 0.85; margin-bottom: 4px; }

/* 個別投稿プロフィール：bioブロックを円の左右端・下端まで広げて下の色を敷く */
.single-author-circle { padding-bottom: 0 !important; }
.single-author-circle .profile-bio { margin: 6px -1.8rem 0; padding: 10px 1.8rem 1.8rem; align-self: stretch; }


/* ============================================================
   外部リンク ブログカードのCSSは css/link-card.css に分離
   （エディタ画面にも読み込ませるため）
============================================================ */

/* ============================================================
   目次（自動・見出し3つ以上の記事のみ）
============================================================ */
.nacolle-toc { background: var(--color-hero-bg, #F0FAFA); border: 3px solid var(--color-main, #48C9C2); border-radius: 12px; padding: 1rem 1.25rem; margin: 0 0 1.5rem; }
.nacolle-toc-title { font-weight: 700; color: var(--color-main, #48C9C2); margin-bottom: 0.5rem; font-size: 0.95rem; letter-spacing: 1px; }
.nacolle-toc-list { margin: 0; padding-left: 1.3rem; }
.nacolle-toc-list li { margin: 3px 0; font-size: 0.9rem; line-height: 1.6; }
.nacolle-toc-list a { color: var(--color-text, #222); }
.nacolle-toc-list a:hover { color: var(--color-main, #48C9C2); }
.post-single-content h2[id^="toc-"], .page-content h2[id^="toc-"] { scroll-margin-top: 90px; }

/* ============================================================
   トップ：左上ロゴブロブ（歪み円。ヘッダー・ロゴ背景と同色ティールで一体化）
   絶対配置でページ左上の角からはみ出す。トップのみ表示。
============================================================ */
.home-logo-blob {
  position: absolute; top: -180px; left: -90px;
  width: 396px; height: 396px; z-index: 110;
  background: var(--color-main, #48C9C2);
  border-radius: 58% 42% 60% 40% / 52% 45% 55% 48%;
  overflow: hidden; display: block;
  transition: border-radius 0.35s ease, transform 0.25s ease;
}
.home-logo-blob img {
  position: absolute; left: 50%; top: 50%;
  height: 142px; width: auto;
  transform: translate(calc(-50% + 20px), calc(-50% + 64px));
}
.home-logo-blob:hover { opacity: 1; transform: scale(1.03); border-radius: 52% 48% 56% 44% / 46% 56% 44% 54%; }
/* トップのコンテンツ位置調整（ブロブとの重なり回避） */
.home .hero .hero-text { margin-left: 284px; }
.home .team-layout .section-label { margin-left: 196px; }
/* スマホ・タブレット（1カラム時）：丸は非表示・元のレイアウト */
@media (max-width: 900px) {
  .home-logo-blob { display: none; }
  .home .hero .hero-text { margin-left: 0; }
  .home .team-layout .section-label { margin-left: 0; }
}
