@charset "utf-8";
.product-feature-container {

    max-width: 960px; /* (954px = 4 * 221px + 3 * 20px) */
    margin: 0 auto;
    padding: 20px 10px;
    display: flex;
    flex-wrap: wrap; 
    gap: 20px; 
}


.product-card {

    width: 220px; 
    flex-grow: 0; 
    flex-shrink: 0; 
    display: flex;
    flex-direction: column;

    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden; 
    text-decoration: none; 
    color: #333;
	box-shadow: 0 0 5px 0 #ccc;
    transition: box-shadow 0.3s ease, opacity 0.3s ease; /* ホバー時のトランジション */
}


.product-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    opacity: 0.8; /* ホバー時に半透明化 */
    text-decoration: none; /* ホバー時の下線削除 */
}


.product-card-image {
    width: 100%;
    height: 150px; 
    overflow: hidden;
    flex-shrink: 0; 
    position: relative; /* タグを絶対配置するために必要 */
}

/* E列のタグのスタイルを再追加 */
.product-tag {
    position: absolute;
    top: 0;
    left: 0;
    padding: 4px 8px;
    background-color: #e74c3c; /* 背景 赤 */
    color: #ffeb3b; /* 文字 黄色 */
    font-size: 0.9rem;
    font-weight: bold;
    z-index: 10;
    border-top-left-radius: 8px; /* カードの角と揃える */
}

/* SALEの場合 */
.product-tag.tag-sale {
    background-color: #d9534f; /* 濃い赤 */
    color: #ffffff;
}



.product-card-image img {
    width: 100%;
    height: 150px;
    object-fit: cover; 
}


.product-card-body {
    padding: 10px;
    display: flex;
    flex-direction: column;
    flex-grow: 1; 
}


.product-card-title { 
    font-size: 1.0rem; 
    font-weight: bold; 
    margin-bottom: 5px; 
    flex-shrink: 0; 
	text-align: justify;
}

.product-card-subtitle { 
    font-size: 0.9rem; 
    color: #666; 
	text-align: justify;
    margin-bottom: 10px; 
    flex-grow: 1; /* 後続の要素を下端に押し下げる */
}
.product-card-price { 
    font-size: 1.1rem; 
    color: #d9534f; 
    font-weight: bold; 
    flex-shrink: 0; 
	text-align: justify;
}
.product-card-period { 
    font-size: 0.85rem; 
    color: #999; 
	text-align: justify;
	margin-left: -10px; /* 左のパディングを相殺 */
	padding-top: 5px;
    padding-left: 10px; /* 左のパディングを維持しながら、元の位置に要素全体を戻す */
    flex-shrink: 0; 
}

/* 商品がない場合のメッセージスタイル */
.empty-message, .error-message {
    font-size: 1.5rem;
    font-weight: bold;
    color: #cc0000; 
    text-align: center;
    width: 100%; 
    padding: 50px 0;
}


/*  スマートフォン表示での調整 (768px以下で1カラムに変更) */
@media (max-width: 768px) {
    .product-feature-container {
        padding: 20px;
        gap: 20px;
    }
    
    .product-card {
        width: 100%;
        min-width: unset; 
    }
    
    .product-card-image {
        width: 100%;
        height: 200px; /* スマホでは画像を大きく */
    }

    .product-card-image img {
        width: 100%;
        height: 200px;
        object-fit: cover; 
    }
    
    /* スマホ時の文字サイズ調整 */
    .product-card-body {
        padding: 15px; /* パディングを広めに */
    }
    
    .product-card-title { 
        font-size: 1.4rem; 
    }

    .product-card-subtitle { 
        font-size: 1.2rem; 
    }
    .product-card-price { 
        font-size: 1.5rem; 
    }
    .product-card-period { 
        font-size: 1.2rem; 
    }
}