
:root {
  --bg-primary: #FAF8F5;
  --bg-card: #FFFFFF;
  --text-main: #2D2520;
  --text-muted: #7A6F68;
  --accent-orange: #E05A2B;
  --accent-light: #FFF0E8;
  --border-color: #EDE6DF;
  --mashu-color: #3895D3;
  --popo-color: #E86A92;
  --moka-color: #4CAF50;
  --shadow-sm: 0 2px 8px rgba(60, 40, 20, 0.05);
  --shadow-md: 0 6px 20px rgba(60, 40, 20, 0.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Hiragino Sans", "Hiragino Kaku Gothic ProN", sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.85;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

header {
  background: #FFFFFF;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.nav-container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-logo {
  font-family: 'Zen Maru Gothic', sans-serif;
  font-size: 1.35rem;
  font-weight: 900;
  color: var(--accent-orange);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: opacity 0.2s;
}

.site-logo:hover {
  opacity: 0.85;
}

.site-logo-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.nav-links {
  display: flex;
  gap: 20px;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--accent-orange);
}

.main-container {
  max-width: 780px;
  margin: 40px auto 80px;
  padding: 0 20px;
}

.article-card {
  background: var(--bg-card);
  border-radius: 20px;
  padding: 44px 48px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-md);
}

@media (max-width: 640px) {
  .article-card {
    padding: 24px 20px;
    border-radius: 14px;
  }
}

.article-header {
  margin-bottom: 28px;
}

.article-date-badge {
  display: inline-block;
  background: var(--accent-light);
  color: var(--accent-orange);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 12px;
  margin-bottom: 12px;
}

.article-title {
  font-size: 1.85rem;
  font-weight: 800;
  line-height: 1.4;
  color: var(--text-main);
  margin-bottom: 20px;
}

.featured-img-wrap {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 32px;
  box-shadow: var(--shadow-sm);
  background: #EFE8E0;
}

.featured-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.video-container {
  margin: 32px 0;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  background: #000;
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.article-body {
  font-size: 1.05rem;
  color: #332B25;
}

.article-body p {
  margin-bottom: 1.6em;
}

.article-body h2 {
  font-size: 1.45rem;
  font-weight: 800;
  margin: 2.2em 0 0.8em;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--accent-light);
  color: var(--text-main);
}

.article-body h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 1.8em 0 0.6em;
  color: #4A3E37;
}

.article-body a {
  color: var(--accent-orange);
  text-decoration: underline;
  text-underline-offset: 3px;
  word-break: break-all;
}

.article-body a:hover {
  opacity: 0.8;
}

.article-body ul, .article-body ol {
  margin: 1.2em 0 1.6em 1.5em;
}

.article-body li {
  margin-bottom: 0.5em;
}

.article-body blockquote {
  border-left: 4px solid var(--accent-orange);
  padding: 12px 18px;
  margin: 1.6em 0;
  background: var(--accent-light);
  border-radius: 0 10px 10px 0;
  font-style: italic;
}

/* リンクカード (Link Card / Blog Card) */
.link-card {
  display: flex !important;
  background: #FFFFFF !important;
  border: 1px solid #E5DFD7 !important;
  border-radius: 14px !important;
  overflow: hidden !important;
  text-decoration: none !important;
  color: inherit !important;
  margin: 20px 0 28px !important;
  box-shadow: 0 3px 12px rgba(60, 42, 30, 0.05) !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease !important;
  min-height: 120px;
}

.link-card:hover {
  transform: translateY(-3px) !important;
  box-shadow: 0 8px 24px rgba(60, 42, 30, 0.12) !important;
  border-color: #D95A2B !important;
  opacity: 1 !important;
}

.link-card-body {
  flex: 1;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-width: 0;
}

.link-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.45;
  color: #2D2520;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
}

.link-card-desc {
  font-size: 0.84rem;
  color: #7A6F68;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 8px;
}

.link-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: #998C82;
  margin-top: 4px;
}

.link-card-favicon {
  width: 16px;
  height: 16px;
  border-radius: 3px;
  display: block;
}

.link-card-domain {
  font-weight: 600;
}

.link-card-thumb-wrap {
  width: 190px;
  min-width: 190px;
  background: #F0E6D8;
  position: relative;
  overflow: hidden;
}

@media (max-width: 600px) {
  .link-card-thumb-wrap {
    width: 120px;
    min-width: 120px;
  }
  .link-card-body {
    padding: 12px 14px;
  }
  .link-card-title {
    font-size: 0.95rem;
  }
}

.link-card-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* 3羽の紹介バッジ */
.character-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: bold;
  color: #fff;
  margin-right: 6px;
}
.char-mashu { background-color: var(--mashu-color); }
.char-popo  { background-color: var(--popo-color); }
.char-moka  { background-color: var(--moka-color); }

/* バックナンバー一覧・カード */
.archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.archive-card {
  background: #FFF;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}

.archive-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.archive-thumb {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #F0E6D8;
}

.archive-content {
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.archive-date {
  font-size: 0.8rem;
  color: var(--accent-orange);
  font-weight: 700;
  margin-bottom: 6px;
}

.archive-title {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 10px;
}

.archive-excerpt {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-top: auto;
}

/* ギャラリースタイル */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.gallery-card {
  background: #FFF;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}

.gallery-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.gallery-thumb-wrap {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #F0E6D8;
  overflow: hidden;
}

.gallery-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

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

.gallery-info {
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.gallery-title {
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 12px;
}

.gallery-actions {
  display: flex;
  gap: 10px;
  margin-top: auto;
}

.btn {
  display: inline-block;
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none !important;
  text-align: center;
  transition: opacity 0.2s;
  border: none;
  cursor: pointer;
}

.btn:hover { opacity: 0.85; }

.btn-primary {
  background: var(--accent-orange);
  color: #FFF !important;
}

.btn-secondary {
  background: var(--accent-light);
  color: var(--accent-orange) !important;
  border: 1px solid #F5D3C4;
}

/* キャラクタープロファイル */
.char-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.char-profile-card {
  background: #FFF;
  border-radius: 16px;
  padding: 20px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  display: flex;
  gap: 16px;
  align-items: center;
}

.char-profile-thumb {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--accent-light);
  flex-shrink: 0;
}

.char-profile-info {
  flex: 1;
}

/* モーダル画像拡大 */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(4px);
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.modal.active { display: flex; }

.modal-content {
  max-width: 95vw;
  max-height: 90vh;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.5);
  object-fit: contain;
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 28px;
  color: #FFF;
  font-size: 36px;
  font-weight: bold;
  cursor: pointer;
  background: none;
  border: none;
}

footer {
  text-align: center;
  padding: 32px 20px;
  font-size: 0.85rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border-color);
  background: #FFFFFF;
}
