
/* Desktop size adjustments for cards (3 columns with fixed width) */
@media (min-width: 1200px) {
  .post_list_works {
      grid-template-columns: repeat(3, 300px); /* 3列固定幅 300px */
      justify-content: center; /* カードを中央に配置 */
      gap: 20px; /* カード間のスペースを保持 */
  }
}

/* Responsive layout for smaller screens */
@media (max-width: 1199px) {
  .post_list_works {
      grid-template-columns: repeat(3, 1fr); /* 3列の自動調整 */
      gap: 20px;
  }
}

@media (max-width: 900px) {
  .post_list_works {
      grid-template-columns: repeat(2, 1fr); /* 2列にする */
  }
}

@media (max-width: 600px) {
  .post_list_works {
      grid-template-columns: 1fr; /* 1列にする */
  }
}



body.archive-works .container.archive-works .post-list {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 20px !important;
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* 新しいクラス名を使用 */
body.archive-works .container.archive-works .works_post_list_item {
    flex: 1 1 calc(33.333% - 20px) !important;
    box-sizing: border-box !important;
    margin-bottom: 20px !important;
    border: 1px solid #e0e0e0 !important;
    padding: 10px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    background-color: #fff !important;
    transition: box-shadow 0.3s ease !important;
}

body.archive-works .container.archive-works .works_post_list_item:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

body.archive-works .container.archive-works .works_post_list_item .imgarea {
    width: 100%;
    margin-bottom: 10px;
    position: relative;
    overflow: hidden;
}

body.archive-works .container.archive-works .post_thumbnail {
    width: 100%;
    height: auto;
    display: block;
}

body.archive-works .container.archive-works .textarea {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

body.archive-works .container.archive-works .list_item_title {
    font-size: 1.2em;
    color: #333;
}

body.archive-works .container.archive-works .bassui {
    font-size: 0.9em;
    color: #666;
    flex-grow: 1;
}

body.archive-works .container.archive-works .pagination {
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
}

body.archive-works .container.archive-works .pagination a,
body.archive-works .container.archive-works .pagination .page-numbers.current {
    display: inline-block;
    padding: 8px 16px;
    margin: 0 4px;
    background-color: #f4f4f4;
    color: #333;
    border: 1px solid #ddd;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

body.archive-works .container.archive-works .pagination .page-numbers.current {
    background-color: #c3c3c3;
    color: #fff;
    border-color: #c3c3c3;
}

body.archive-works .container.archive-works .pagination a:hover,
body.archive-works .container.archive-works .pagination .page-numbers.current:hover {
    background-color: #e9ecef;
    color: #000;
}

/* レスポンシブ対応 */
@media (max-width: 992px) {
    body.archive-works .container.archive-works .works_post_list_item {
        flex: 1 1 50%;
    }
}

@media (max-width: 768px) {
    body.archive-works .container.archive-works .works_post_list_item {
        flex: 1 1 100%;
    }
}

.sub_title {
    position: relative;
    font-size: 1.2em;
    font-weight: 900;
    line-height: 1.5em;
    margin-top: 1em;
    margin-bottom: 1em;
}

.works-category-title {
    margin-bottom: 5%;
    font-size: 2em;
}


.custom-img-size {
    width: 80%; /* 画像の幅を90%に設定 */
    max-width: 80%; /* 親要素の幅を超えないようにする */
    height: auto; /* アスペクト比を維持 */
    display: block;
    margin: 0 auto; /* 画像を中央揃えにする */
}

.post-thumbnail-solution {
    background-color: #fff;
    padding: 1.0em; /* 本文と同じパディングを適用 */
    margin-bottom: 20px; /* 下に適度なスペースを追加 */
}

.post-thumbnail-solution img {
    display: block;
    margin-bottom: 15px; /* タグとの間にスペースを追加 */
}

.post-solution {
    font-size: 14px;
    color: #666;
}

.post-solution a {
    display: inline-block; /* ボタン風にするためにインラインブロックに設定 */
    color: #555555;
    background-color: #f0f0f0; /* ボタンの背景色 */
    padding: 5px 10px; /* 内側の余白を調整 */
    border-radius: 3px; /* 角を丸める */
    text-decoration: none;
    margin-right: 5px; /* ボタン間の隙間を設定 */
    font-weight: bold; /* ボタンのテキストを太字に */
    transition: background-color 0.3s, color 0.3s; /* ホバー時のアニメーションを追加 */
}

.post-solution a:hover {
    background-color: #ff2200; /* ホバー時に背景色を変更 */
    color: #fff; /* ホバー時にテキストの色を変更 */
    text-decoration: none; /* ホバー時に下線を非表示 */
}


.post_tags {
    margin-top: 10px;
    font-size: 0.9em;
}

.post_tags a {
    background-color: #f0f0f0;
    color: #333;
    padding: 5px 10px;
    margin-right: 5px;
    border-radius: 3px;
    text-decoration: none;
}

.post_tags a:hover {
    background-color: #0073aa;
    color: #fff;
}

.post-solution {
    font-size: 14px;
    color: #666;
}


.solution-tag {
  display: inline-block;
  background-color: #f0f0f0;
  padding: 5px 10px;
  border-radius: 3px;
  margin: 0 5px 10px 0; /* 上: 0, 右: 5px, 下: 5px, 左: 0 */
  font-weight: bold;
  color: #555;
  transition: background-color 0.3s, color 0.3s;
}

.industry-label {
    font-weight: bold;
    margin-right: 5px;
    color: #333;
}

.post-industry {
    margin-top: 10px;
}

.post-industry .industry-tag {
    margin-right: 10px; /* タグ間のスペースを設定 */
    color: #555; /* リンクの色を #555 に設定 */
    text-decoration: underline; /* アンダーバーを表示 */
}

.post-industry .industry-tag:last-child {
    margin-right: 0; /* 最後のタグの右側にはスペースを入れない */
}

.post-industry .industry-tag:hover {
    color:#999; /* ホバー時の色を濃いグレーに変更（オプション） */
    text-decoration: underline; /* ホバー時もアンダーバーを維持 */
}


/* 親リストのスタイル */
.post_list_works {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* 3列レイアウト */
    gap: 20px;
    list-style: none;
    margin: 0;
    padding: 0;
  }
  
.works_post_list_item_works {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background-color: #fff;
    padding: 15px;
    border: 1px solid #ececec;
    border-radius: 8px;
    box-shadow: 0 3px 4px rgba(110, 110, 110, 0.1);
    transition: transform 0.2s ease;
    width: 100%;
  }

.post_list_item_works {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: space-between; /* カードを均等に配置 */
}

/* ホバー時のエフェクト */
.works_post_list_item_works:hover {
    transform: translateY(-5px);
}

/* 画像エリア */
.imgarea_works {
  display: block;
  width: 100%;
}

.post_thumbnail_works {
  width: 100%;
  height: auto;
  display: block;
}

/* テキストエリア */
.textarea_works {
  padding: 15px;
}

/* 企業名 */
.company_name_works {
  font-size: 14px;
  font-weight: bold;
  margin-bottom: 10px;
  color: #333;
}

/* works_tag */
.post_category_works {
  font-size: 12px;
  color: #777;
  margin-bottom: 10px;
}

/* タイトル */
.list_item_title_works {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 10px;
  color: #000;
}

/* industry タグ */
.industry_tags_works {
  font-size: 12px;
  color: #555;
}



/* 親リストのスタイル */
.post_list_works {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3列にする */
    gap: 20px; /* 各カードの間にスペースを追加 */
    list-style-type: none; /* リストのスタイルを無効化 */
    margin: 0;
    padding: 0;
  }

  
  
  /* カード全体のスタイル */
  .works_card_works {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-sizing: border-box;
    border: 1px solid #ececec;
    border-radius: 8px;
    box-shadow: 0 3px 4px rgba(110, 110, 110, 0.1);
    padding: 15px;
    transition: transform 0.2s ease;
    flex: 1 1 calc(30% - 20px) !important; /* 必要なら !important を追加 */
    margin-bottom: 20px;
}
  
  .works_card_works:hover {
    transform: translateY(-5px); /* ホバー時のエフェクト */
  }
  
  
  .works_post_thumbnail_works {
    width: 100%;
    height: auto;
  }
  
  /* テキストエリア */
  .works_textarea_works {
    padding: 15px;
  }
  
  /* 企業名 */
  .works_company_name_works {
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 5px;
    color: #333;
  }
  
  /* works_tag */
  .works_post_category_works {
    font-size: 12px;
    color: #777;
    margin-bottom: 10px;
  }

  .works_post_category_works a {
    font-size: 12px;
    color: #777; /* グレーの文字色 */
    text-decoration: underline; /* 下線付き */
}

.works_post_category_works a:hover {
    color: #555; /* ホバー時の色を少し濃いグレーに変更 */
    text-decoration: underline; /* ホバー時も下線付き */
}
  
/* タイトル部分の高さを3行に固定 */
.works_list_item_title_works {
    font-size: 18px;
    font-weight: bold;
    line-height: 1.3;
    height: calc(1.5em * 3); /* タイトルの高さを固定 */
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}
  
  /* industry タグ */
  .works_industry_tags_works {
    font-size: 12px;
    color: #555;
    white-space: nowrap; /* テキストを折り返さない */
}

/* リンクのスタイル（リンク色をグレーに） */
.works_industry_tags_works a {
    color: #555 !important; /* リンクの色をグレーに */
    text-decoration: underline; /* 下線を追加 */
}

/* リンクにホバーしたときのスタイル */
.works_industry_tags_works a:hover {
    color: #333; /* ホバー時に濃いグレーに変更 */
    text-decoration: underline; /* ホバー時も下線を維持 */
}


  /* 親コンテナのスタイル */
.container.archive-works_works {
    width: 100%;
    max-width: 1200px;
    padding:　10px;
  }
  
  /* 横並びのFlexbox設定 */
  .side_on_works {
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-between;
  }
  
  .left_works {
    flex: 1; /* メインコンテンツの横幅 */
    padding-right: 30px;
  }
  
  .right_works {
    flex: 0 0 300px; /* 固定幅のサイドバー */
    padding-right: 30px;
  }
  
  /* グリッドレイアウトの設定 */
  .post_list_works {
    display: grid;
    grid-template-columns: repeat(2, minmax(300px, 1fr)); /* カード幅を250px～自動調整に */
    gap: 20px; /* 各カード間のスペース */
    margin: 0;
    padding: 0;
    list-style: none;
  }
  
  
  .works_card_works:hover {
    transform: translateY(-5px);
  }
  
/* 画像の親要素に固定の幅と高さを指定 */
.works_imgarea_works {
    width: 100%;
    aspect-ratio: 1.6; /* 比率を維持 */
    background-color: #f0f0f0;
    overflow: hidden;
    position: relative; /* 画像を中央に配置するため */
}


.works_imgarea_works img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* カード内に収まるように表示 */
    object-position: center; /* 画像を中央に配置 */
    display: block;
    padding-bottom: 10px;
    background-color: #fff;
}


/* 画像を親要素に合わせてトリミング */
.works_post_thumbnail_works {
    width: 100%;
    height: 100%;
    object-fit: cover; /* 画像をトリミングして表示 */
    object-position: center; /* 画像の中央部分を表示 */
}
  
  .works_textarea_works {
    padding: 15px;
  }
  
  .works_company_name_works, .works_post_category_works, .works_list_item_title_works, .works_industry_tags_works {
    margin-bottom: 3px;
    margin-top: 3px;
    color: #555;
  }
  
  /* レスポンシブ対応 */
@media (max-width: 900px) {
    .post_list_works {
        grid-template-columns: repeat(2, 1fr); /* 2列にする */
    }
}
  
@media (max-width: 600px) {
    .post_list_works {
        grid-template-columns: 1fr; /* 1列にする */
    }
}

.no-results-message {
    text-align: center;
    margin-top: 20px;
    font-size: 16px;
    color: #555;
}

/* Desktop size adjustments for .left_works */
@media (min-width: 1200px) {
  .left_works {
      flex: 0 0 75%; /* Set the width to 70% for the main content */
      max-width: 75%; /* Maximum width */
      margin-bottom: 80px;
    }

  .right_works {
      flex: 0 0 300px; /* Fixed width for the sidebar */
      max-width: 300px; /* Ensure the sidebar doesn't exceed this width */
  }
}

/* Keep the responsive layout for smaller devices */
@media (max-width: 1199px) {
  .left_works {
      flex: 1; /* Allow flexible width for the main content */
      padding-right: 30px; /* Maintain padding */
  }

  .right_works {
      flex: 0 0 ２00px; /* Fixed width for the sidebar */
  }
}


.side_navi li {
  border-bottom: 1px dotted #ccc !important; /* 点線を強制的に適用 */
  padding-bottom: 10px !important; /* パディングを強制的に適用 */
  margin-bottom: 10px !important; /* マージンを強制的に適用 */
}

img.alignright {
  display: block;
  width: 100px; /* 横幅を100pxに固定 */
  height: auto; /* 高さを自動調整してアスペクト比を維持 */
  float: right; /* 右揃え */
  margin-left: 10px; /* 左側に余白を設定 */
  margin-bottom: 10px; /* 下に余白を設定 */
  position: relative; /* 位置を制御可能にする */
  z-index: 9999; /* 前面に表示されるように設定 */
}

.qr-links {
  display: flex; /* 横並び配置 */
  justify-content: flex-end; /* 全体を右揃え */
  align-items: flex-start; /* 上揃えにする */
  gap: 10px; /* アイテム間のスペース */
}

.qr-image {
  width: 100px !important; /* 強制的に横幅を100pxに設定 */
  height: auto; /* 高さをアスペクト比に基づいて自動調整 */
  max-width: 100%; /* 親要素より大きくならないように制約 */
}