/*
Theme Name: ai-do
Template: ystandard
Version: 1.0.0
*/
/* outer container */
.container.layout-wide {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 2rem;
  padding-right: 2rem;
  box-sizing: border-box;
}

@media (max-width: 767px) {
  .container.layout-wide {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

/* ✅ 表示切り替え：PCでsp非表示、スマホでpc非表示 */
#fixed-banner-pc {
  display: flex !important;
}
#fixed-banner-sp {
  display: none !important;
}
@media (max-width: 767px) {
  #fixed-banner-pc {
    display: none !important;
  }
  #fixed-banner-sp {
    display: flex !important;
  }
}
/* ✅ PC・タブレット用（右中央に固定） */
#fixed-banner-pc {
  position: fixed;
  top: 30%;
  right: 0;
  z-index: 9999;
  flex-direction: column;
  gap: 10px;
}

.float-banner {
  writing-mode: vertical-rl;
  text-align: center;
  width: 50px;
  color: #fff;
  font-weight: bold;
  text-decoration: none;
  border-radius: 6px 0 0 6px;
  position: relative;
  transition: all 0.3s ease;
  font-size: 12px;
  padding: 8px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  border: 2px solid transparent;
}

/* ✅ 白い点（::before）削除 */
.float-banner::before {
  content: none;
}

/* ✅ 通常色指定 */
.banner-sample  { background-color: #BA1C22; }
.banner-shop    { background-color: #018730; }
.banner-contact { background-color: #707070; }

/* ✅ ホバー時：白背景＋枠線＋文字色 */
.banner-sample:hover {
  background-color: #ffffff;
  color: #BA1C22;
  border-color: #BA1C22;
}

.banner-shop:hover {
  background-color: #ffffff;
  color: #018730;
  border-color: #018730;
}

.banner-contact:hover {
  background-color: #ffffff;
  color: #707070;
  border-color: #707070;
}

/* ✅ スマホ用（右中央に固定） */
#fixed-banner-sp {
  position: fixed;
  top: 40%;
  right: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ✅ スマホ用アイコンバナー（PC版に近い角丸長方形） */
.float-icon {
  width: 50px;
  height: 50px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

/* 通常色：PCと同じ */
.icon-sample  { background-color: #BA1C22; }
.icon-shop    { background-color: #018730; }
.icon-contact { background-color: #707070; }

/* ホバー時：白背景＋元の色で文字色・枠線表示 */
.icon-sample:hover {
  background-color: #ffffff;
  color: #BA1C22;
  border-color: #BA1C22;
}
.icon-shop:hover {
  background-color: #ffffff;
  color: #018730;
  border-color: #018730;
}
.icon-contact:hover {
  background-color: #ffffff;
  color: #707070;
  border-color: #707070;
}

.float-icon img {
  width: 20px;
  height: 20px;
}
/* リコメンドエリア */
.related-posts {
  margin-top: 3em;
}

.related-posts-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5em;
  margin-top: 1.7em;
}

.related-post {
  width: calc(33.333% - 1em);
  text-align: center;
}

.related-post-thumbnail img {
  width: 100%;
  height: auto
  object-fit: cover;
  border-radius: 0 !important;
}

.related-post-title {
  font-size: 1rem;
  margin-top: 0.5em;
  color: #333;
  text-align: left; 
  text-decoration: none; 
  border-bottom: none !important;
}

.related-post-title a {
  text-decoration: none !important;
  border-bottom: none !important;
  background-image: none !important;
  background: none !important;
  color: #000 !important;
}

.related-post-title a:hover {
  color: #B91C22 !important;
  text-decoration: none;
}
@media screen and (max-width: 768px) {
  .related-post {
    width: 100% !important;
  }
}
/* ▼ 前後記事：左右配置、画像とタイトル横並び */
.post-navigation.side-by-side {
  margin-top: 3em;
  display: flex;
  justify-content: space-between;
  gap: 2em;
}

.post-navigation.side-by-side .nav-previous,
.post-navigation.side-by-side .nav-next {
  width: 48%;
}

/* 横並び、中央揃え */
.post-navigation.side-by-side .nav-previous a,
.post-navigation.side-by-side .nav-next a {
  display: flex;
  align-items: center;
  gap: 1em;
  text-decoration: none;
}

/* 前後どちらも [画像] [タイトル] の順で統一 */
.post-navigation.side-by-side .nav-previous a,
.post-navigation.side-by-side .nav-next a {
  flex-direction: row;
}

/* 左右テキスト整列 */
.post-navigation.side-by-side .nav-previous {
  text-align: left;
}

.post-navigation.side-by-side .nav-next {
  text-align: right;
}

.post-navigation.side-by-side .nav-thumb img {
  width: 108px;
  height: 61px;
  object-fit: cover;
  border-radius: 4px;
}

.post-navigation.side-by-side .nav-title {
  font-size: 1em;
  font-weight: bold;
  color: #0073aa;
  line-height: 1.4;
}

/* モバイル対応：縦並びに */
@media screen and (max-width: 768px) {
  .post-navigation.side-by-side {
    flex-direction: column;
    gap: 2em;
  }

  .post-navigation.side-by-side .nav-previous,
  .post-navigation.side-by-side .nav-next {
    width: 100%;
    text-align: left;
  }

  .post-navigation.side-by-side .nav-next a {
    flex-direction: row;
    justify-content: flex-start;
  }
}
