/*
Template: jin
Theme Name: jin-child
Author: CrossPiece
Version: 1.00
*/
/* style.css に追加または更新 */
#sidebar{
    background-color: rgba(255, 255, 255, 0.8);
}
.sidebar_style2 .widget{
    padding: 0!important;
}
.my-profile{
    color: #f8f8f8!important;
}
.cps-post .cps-post-thumb img{
    border-radius: 18px;
}
.post-list-mag .post-list-item .post-list-inner .post-list-thumb {
    position: relative; /* 子要素の絶対配置の基準にする */
    width: 100%; /* 親要素の幅いっぱいに広げる */
    padding-top: 75%; /* 4:3のアスペクト比 (3 / 4 * 100 = 75%) */
    overflow: hidden; /* 子要素がはみ出さないように */
}

.post-list-mag .post-list-item .post-list-inner .post-list-thumb img { /* もし画像要素がある場合 */
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* 画像がボックスに合わせてトリミングされるように */
}
/* タブコンテナのスタイル (変更なし) */
.tab-container {
    width: 100%;
    overflow: hidden;
    border: 1px solid #869e53;
    border-radius: 5px;
    margin-bottom: 20px;
    background-color: #e8ede8;
}

/* タブボタンのスタイル (変更なし) */
.tab-buttons {
    display: flex;
    border-bottom: 1px solid #869e53;
}

.tab-button {
    flex: 1;
    padding: 10px 15px;
    cursor: pointer;
    background-color: #fff;
    text-align: center;
    border-right: 1px solid #869e53;
    transition: background-color 0.3s ease;
}

.tab-button:last-child {
    border-right: none;
}

.tab-button.active {
    background-color: #8fbc8f;
    color: #fff;
    border-bottom: 2px solid #869e53;
    margin-bottom: -1px;
}

.tab-button:hover:not(.active) {
    background-color: #efefef;
}

/* タブコンテンツのスタイル (変更なし) */
.tab-content {
    padding: 15px;
    background-color: #fff;
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

/* リンク一覧のスタイル */
.link-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
    /* ↓↓ ここから追加・変更 ↓↓ */
    display: flex; /* Flexboxを有効にして子要素を横並びに */
    flex-wrap: wrap; /* 要素が収まらない場合に折り返す */
    gap: 10px 20px; /* アイテム間の隙間 (上下10px, 左右20px) */
    /* ↑↑ ここまで追加・変更 ↑↑ */
}

.link-list li {
    /* ↓↓ ここから変更 ↓↓ */
    /* margin-bottom: 8px; は不要になるか、調整 */
    margin-bottom: 0; /* Flexboxのgapを使うため、既存のマージンをリセット */
    /* ↑↑ ここまで変更 ↑↑ */
}

.link-list a {
    text-decoration: none;
    color: #FF8C00;
    font-size: 15px;
    transition: color 0.2s ease;
    white-space: nowrap; /* リンクテキストが途中で改行されないように */
}

.link-list a:hover {
    color: #A52A2A;
    text-decoration: underline;
}

/* スマートフォンでの表示調整 */
@media (max-width: 768px) { /* PCとスマホの切り替えブレークポイントを調整 */
    .link-list ul {
        flex-direction: column; /* スマートフォンでは縦並びに戻す */
        gap: 8px 0; /* スマートフォンでの縦の隙間 */
    }

    .link-list li {
        margin-bottom: 0; /* Flexboxのgapを使うため */
    }
}

/*Ranking*/
.ranking-thumbnail img{
    width: 100%;
    height: auto;
}
.ranking-position{
    font-size: 24px;
    font-weight: bold;
    color: #FF8C00;
    margin-bottom: 10px;
}
/* cookpadリンクカードの表示調整 */
.cookpad-link-card {
    border: 1px solid #ccc;
    border-radius: 8px;
    overflow: hidden;
    margin: 20px 0;
    max-width: 500px; /* カードの最大幅を調整 */
    background-color: #fff;
    
    /* ↓↓ この部分が影を作るプロパティです ↓↓ */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15); /* X軸オフセット、Y軸オフセット、ぼかし半径、拡散半径、色 */
    transition: box-shadow 0.3s ease; /* ホバー時の滑らかなアニメーション */
}

.cookpad-link-card:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.25); /* ホバー時に影を強調 */
}

/* 以下のCSSは以前と同じです（変更なし） */

.cookpad-link-card a {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    padding: 10px;
}

.cookpad-link-card .card-image {
    flex-shrink: 0;
    width: 80px; /* 画像の幅 */
    height: 80px; /* 画像の高さ */
    margin-right: 15px;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #f8f8f8; /* 画像背景色 */
    border-radius: 4px;
}

.cookpad-link-card .card-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain; /* アスペクト比を維持して収める */
}

.cookpad-link-card .card-content {
    flex-grow: 1;
}

.cookpad-link-card .card-title {
    font-weight: bold;
    font-size: 1.1em;
    color: #e54242; /* Cookpad のブランドカラーに合わせる */
    margin-bottom: 5px;
}

.cookpad-link-card .card-description {
    font-size: 0.9em;
    color: #555;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis; /* 長いURLを省略表示 */
}

/* スマートフォンでの表示調整 */
@media (max-width: 600px) {
    .cookpad-link-card a {
        flex-direction: column;
        text-align: center;
    }

    .cookpad-link-card .card-image {
        margin-right: 0;
        margin-bottom: 10px;
    }
}

/* お知らせ一覧のスタイル */
.notices-list {
    display: grid;
    gap: 1.5rem;
    padding: 1rem;
}

.notice-item {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.notice-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.notice-item a {
    display: block;
    padding: 1.5rem;
    text-decoration: none;
    color: inherit;
}

.notice-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin: 0 0 0.5rem;
    line-height: 1.4;
}

.notice-date {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
}

.notice-date::before {
    content: '📅';
    margin-right: 0.5rem;
}

.notice-excerpt {
    font-size: 0.95rem;
    color: #555;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* レスポンシブ対応 */
@media (min-width: 768px) {
    .notices-list {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
}

@media (max-width: 767px) {
    .notices-list {
        grid-template-columns: 1fr;
    }
    
    .notice-item {
        margin-bottom: 1rem;
    }
    
    .notice-title {
        font-size: 1rem;
    }
}

/* カルーセルスライダーのスタイル */
.post-carousel-slider {
    padding: 0 32px;
    margin: 20px 0;
    background-color: #fff;
}

.post-carousel-slider .swiper-wrapper {
    display: flex;
    width: 100%;
}

.post-carousel-slider .swiper-slide {
    height: auto;
    flex: 0 0 auto;
    margin: 0!important;
}

@media (max-width: 599px) {
    .post-carousel-slider .swiper-slide {
        width: calc(50% - 15px) !important; /* 2カラム */
    }
	.post-thumbnail{
		min-width: 115px;	
	}
}

@media (min-width: 600px) and (max-width: 767px) {
    .post-carousel-slider .swiper-slide {
        width: calc(33.333% - 20px) !important; /* 3カラム */
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .post-carousel-slider .swiper-slide {
        width: calc(25% - 30px) !important; /* 4カラム */
    }
}

@media (min-width: 1024px) {
    .post-carousel-slider .swiper-slide {
        width: calc(32% - 30px) !important; /* 4カラム */
    }
	.post-thumbnail{
		min-width: 230px;	
	}
	.swiper-button-next, .swiper-button-prev{top:45%!important;}
}
.post-card {
    padding: 10px;
}

.post-thumbnail {
    position: relative;
    width: 100%;
    padding-top: 100%; /* アスペクト比を1:1（正方形）に設定 */
    overflow: hidden;
}

.post-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* 画像を正方形に収める */
    border-radius: 8px;
}

.post-title {
    font-size: 14px;
    margin: 10px 0;
    line-height: 1.4;
}

.post-title a {
    color: #333;
    text-decoration: none;
}

.swiper-button-next,
.swiper-button-prev {
    color: #666;
}

/* スマートフォン用のスタイル */
@media (max-width: 767px) {
    .post-carousel-slider {
        padding: 0 30px;
    }
    
    .swiper-button-next,
    .swiper-button-prev {
        transform: scale(0.8);
    }
}
.new-entry .eyecatch img,
.post-list-mag3col-slide .post-list-item .post-list-inner .post-list-thumb img{
  width: 100%; /* 親要素の幅いっぱいに広げる */
  height: auto; /* 高さは自動調整 */
  aspect-ratio: 16 / 9; /* アスペクト比を16:9に設定 */
  object-fit: cover; /* はみ出す部分をトリミングしてカバー */
}
.toppost-list-box-simple .post-list-mag, .toppost-list-box-simple .post-list-mag-sp1col{
	justify-content: flex-start!important;
}
.tn-logo-size .sub{
	font-size: 15px!important;
}