/* =========================================================
  Travel Blog - style.css
  対象HTML: 提示いただいた Blog テンプレート
  フォントは Noto Sans / Noto Sans JP をHTML側で読込済み
========================================================= */

/* ベース設定
--------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  /* スクロールの心地よさ */
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: #222;
  background: #fff;
  font-family: "Noto Sans JP", "Noto Sans", system-ui, -apple-system,
    BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.8;
  letter-spacing: 0.02em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* 共通レイアウト
--------------------------------------------------------- */
.wrapper {
  width: min(1120px, 92%);
  margin-inline: auto;
}

img {
  max-width: 100%;
  height: auto;
  text-align: middle;
  display: block;
  border-radius: 8px;
}

/* アクセシビリティ: フォーカス可視化 */
a {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.2s ease, color 0.2s ease, background-color 0.2s ease;
}
a:focus-visible {
  outline: 3px solid #0ea5e9; /* sky */
  outline-offset: 2px;
  border-radius: 4px;
}

/* タイポグラフィ
--------------------------------------------------------- */
h1, h2, h3, h4 {
  line-height: 1.35;
  font-weight: 700;
  margin: 0 0 0.6em;
}
p {
  margin: 0 0 1.2em;
}

/* ヘッダー
--------------------------------------------------------- */
#header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid #eee;
}

/* ロゴ */
.site-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 14px;
}
.site-title img {
  width: clamp(140px, 18vw, 200px);
}

/* ナビ */
#navi {
  border-top: 1px solid #f1f1f1;
}
#navi ul {
  display: flex;
  gap: clamp(12px, 2.2vw, 28px);
  padding: 12px 0;
  margin: 0;
  list-style: none;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}
#navi a {
  display: inline-block;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #0f172a; /* slate-900 */
}
#navi a:hover {
  background: #0ea5e9; /* sky-500 */
  color: #fff;
}

/* ピックアップ（3カラム）
--------------------------------------------------------- */
#pickup {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 2.2vw, 24px);
  padding: clamp(18px, 2.5vw, 28px) 0;
}

#pickup article {
  display: grid;
  gap: 10px;
}

#pickup .article-title {
  font-size: clamp(14px, 1.6vw, 18px);
  font-weight: 700;
}

.readmore a {
  display: inline-block;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid #0ea5e9;
  color: #0ea5e9;
  font-weight: 700;
  font-size: 0.92rem;
}
.readmore a:hover {
  background: #0ea5e9;
  color: #fff;
}

/* メイン + サイドバー
--------------------------------------------------------- */
#container {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: clamp(24px, 3vw, 40px);
  padding-block: clamp(20px, 3vw, 36px);
}

/* 記事カード */
main article {
  padding-bottom: 28px;
  margin-bottom: 28px;
  border-bottom: 1px solid #eee;
}
main .article-title a {
  font-size: clamp(18px, 2.2vw, 24px);
  color: #0f172a;
}
main .article-title a:hover {
  color: #0ea5e9;
}

/* メタ情報（投稿日・カテゴリ） */
.meta {
  display: flex;
  gap: 12px;
  padding: 0;
  margin: 6px 0 14px;
  list-style: none;
  font-size: 0.92rem;
  color: #475569; /* slate-600 */
}
.meta a {
  color: #475569;
}
.meta a:hover {
  color: #0ea5e9;
}

.text {
  margin-top: 12px;
  color: #374151; /* gray-700 */
}

/* サイドバー
--------------------------------------------------------- */
#sidebar {
  position: sticky;
  top: calc(72px + 24px);
  height: fit-content;
  display: grid;
  gap: 28px;
}

/* 著者 */
.author {
  padding: 18px;
  border: 1px solid #eee;
  border-radius: 12px;
  background: #fafafa;
}
.author img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  margin-bottom: 12px;
  border-radius: 10px;
}
.side-title {
  font-size: 1.05rem;
  margin-bottom: 8px;
}
.profile {
  font-size: 0.95rem;
  color: #475569;
}

/* ランキング */
.ranking {
  padding: 18px;
  border: 1px solid #eee;
  border-radius: 12px;
}
.ranking article + article {
  margin-top: 14px;
}
.ranking a {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 12px;
  align-items: center;
}
.ranking img {
  width: 88px;
  height: 66px;
  object-fit: cover;
  border-radius: 8px;
}
.ranking .article-title {
  font-size: 0.98rem;
  font-weight: 600;
  color: #0f172a;
}
.ranking a:hover .article-title {
  color: #0ea5e9;
}

/* アーカイブ */
.archive {
  padding: 18px;
  border: 1px solid #eee;
  border-radius: 12px;
}
.archive ul {
  list-style: none;
  padding: 0;
  margin: 0;
  columns: 1;
}
.archive li {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 6px 0;
  border-bottom: 1px dashed #eee;
  font-size: 0.95rem;
}
.archive a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.archive a:hover {
  color: #0ea5e9;
}

/* フッター
--------------------------------------------------------- */
#footer {
  margin-top: 40px;
  background: #0f172a; /* slate-900 */
  color: #e5e7eb;      /* gray-200 */
}

#footer .content {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(18px, 3vw, 32px);
  padding-block: clamp(24px, 3.4vw, 40px);
}

#footer .footer-title {
  color: #fff;
  font-size: 1.05rem;
  margin-bottom: 10px;
}

#footer p {
  color: #cbd5e1; /* slate-300 */
}

.about-list,
.menu-list {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: grid;
  gap: 8px;
}
.menu-list a,
.about-list a {
  color: #e5e7eb;
}
.menu-list a:hover,
.about-list a:hover {
  color: #0ea5e9;
}

/* 「→」つきリンク */
.arrow {
  position: relative;
  padding-right: 18px;
}
.arrow::after {
  content: "→";
  position: absolute;
  right: 0;
  top: 0;
}

/* Twitter 埋め込み */
.twitter-timeline {
  width: 100% !important;
  border-radius: 8px;
  overflow: hidden;
}

/* コピーライト */
.copyright {
  margin: 0;
  padding: 14px 0 18px;
  text-align: center;
  font-size: 0.9rem;
  color: #94a3b8; /* slate-400 */
  border-top: 1px solid rgba(255,255,255,0.08);
}

/* ユーティリティ
--------------------------------------------------------- */
.hidden {
  position: absolute !important;
  inline-size: 1px;
  block-size: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ホバー時の画像の軽いリフト効果（カード感UP） */
#pickup article img,
main article > a img,
.ranking img {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
#pickup article:hover img,
main article > a:hover img,
.ranking a:hover img {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(2, 6, 23, 0.12); /* slate-950 */
}

/* レスポンシブ
--------------------------------------------------------- */
/* 1024px 以下：2カラム化など */
@media (max-width: 1024px) {
  #container {
    grid-template-columns: 1fr 280px;
  }
  #pickup {
    grid-template-columns: repeat(2, 1fr);
  }
  .ranking a {
    grid-template-columns: 80px 1fr;
  }
}

/* 768px 以下：1カラム＋余白調整 */
@media (max-width: 768px) {
  #navi ul {
    justify-content: flex-start;
    padding-left: 4%;
  }
  #pickup {
    grid-template-columns: 1fr;
  }
  #container {
    grid-template-columns: 1fr;
  }
  #sidebar {
    position: static;
    top: auto;
  }
  #footer .content {
    grid-template-columns: 1fr;
  }
  .archive ul {
    columns: 1;
  }
}

/* 480px 以下：文字サイズ・余白の微調整 */
@media (max-width: 480px) {
  .readmore a {
    padding: 9px 14px;
    font-size: 0.9rem;
  }
  .meta {
    font-size: 0.9rem;
    flex-wrap: wrap;
    gap: 8px;
  }
  .ranking img {
    width: 76px;
    height: 60px;
  }
}

/* プリント（必要なら） */
@media print {
  #navi, .readmore, .ranking img, .twitter-timeline, script {
    display: none !important;
  }
  a::after {
    content: " (" attr(href) ")";
    font-size: 0.9em;
  }
}