html, body {
    height: 100%;
}

body {
    font-family: sans-serif;
    background-color: #f4f4f4;
    color: #333;
    margin: 0;
    padding: 20px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 40px); /* vhからbodyのpadding分を引く */
}

header {
    text-align: center;
    margin-bottom: 20px;
}

.site-title {
    font-size: 2em;
    font-weight: bold;
    color: #333;
    text-decoration: none;
}

main {
    flex-grow: 1;
}

footer {
    text-align: center;
    padding: 10px 0;
}

h1 {
    text-align: center;
    color: #e91e63;
}

h2 {
    text-align: center;
    color: #e91e63;
    margin-top: 0;
}

#search-form {
    display: flex;
    margin-bottom: 20px;
}

#search-input {
    flex-grow: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px 0 0 4px;
    font-size: 16px;
}

#search-form button {
    padding: 10px 20px;
    border: none;
    background-color: #e91e63;
    color: white;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-size: 16px;
}

#search-form button:hover {
    background-color: #c2185b;
}

.content-section {
    background: #fdfdfd;
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 20px;
}

.content-section h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.1em;
    color: #333;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
    font-weight: 600;
}

#result-container {
    display: flex;
    flex-direction: column; /* 縦並びに変更 */
    gap: 20px;
    margin-top: 20px;
}

#product-info {
    width: 100%; /* 全幅に変更 */
    display: flex;
    flex-direction: column;
    align-items: center; /* 中央揃え */
}

#product-title {
    font-size: 1.2em;
    margin-top: 0;
    text-align: center; /* 中央揃え */
}

/* product-details の修正 */
.product-details {
    display: flex; /* 画像と価格情報を横並びにする */
    align-items: center; /* 中央揃え */
    justify-content: center; /* 中央揃え */
    gap: 20px; /* 画像と価格情報の間隔 */
    flex-wrap: wrap; /* 画面幅が狭い場合に折り返す */
}

.product-details img {
    max-width: 350px; /* 画像の最大幅を調整 */
    max-height: 400px; /* 画像の最大の高さを制限 */
    object-fit: contain; /* アスペクト比を維持 */
    border-radius: 4px;
}

#details-right-column {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* price-info-container の追加 */
#price-info-container {
    flex-grow: 1; /* 残りのスペースを埋める */
    display: flex;
    flex-direction: column; /* 価格情報を縦積み */
    gap: 5px; /* 各価格カテゴリ間の間隔 */
}

/* 各価格カテゴリのスタイル */
.price-category {
    display: flex;
    align-items: baseline; /* ベースラインで揃える */
    font-size: 1.2em; /* フォントサイズを大きく */
}

.category-name {
    font-weight: bold;
    margin-right: 10px; /* 右側のマージンを調整 */
}

.category-name a {
    color: #333; /* リンクの色を調整 */
    text-decoration: none;
}

.category-name a:hover {
    text-decoration: underline;
}

.normal-price {
    color: #e91e63; /* 通常価格の色 */
    font-weight: bold;
}

.original-price {
    color: #999; /* 通常価格の色（セール時） */
    text-decoration: line-through; /* 取り消し線 */
    margin-right: 5px;
}

.sale-price {
    color: #4caf50; /* セール価格の色 */
    font-weight: bold;
    font-size: 1.1em; /* セール価格を少し大きく */
}

/* 「FANZAで見る」ボタンのスタイル */
    #affiliate-link {
        width: 100%; /* 幅を100%に */
    }

    #chart-container {
        height: 300px;
    }
}

#chart-container {
    width: 100%; /* 全幅に変更 */
    position: relative;
    height: 400px;
}

.error {
    color: #d32f2f;
    background-color: #ffcdd2;
    padding: 10px;
    border-radius: 4px;
    margin-top: 10px;
}

#search-suggestions ul {
    list-style: none;
    padding: 0;
}

#search-suggestions li {
    padding: 8px;
    cursor: pointer;
    border-bottom: 1px solid #eee;
}

#search-suggestions li:hover {
    background-color: #f0f0f0;
}

.price-link {
    text-decoration: none;
    color: inherit;
}

/* 検索例セクション */
#search-examples {
    margin: 10px 0 20px;
    padding: 12px 14px;
    border: 1px dashed #cfd8dc;
    background: #fafafa;
    border-radius: 6px;
}

.examples-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #455a64;
    margin-bottom: 8px;
}

.examples-badge {
    display: inline-block;
    font-size: 12px;
    line-height: 1;
    padding: 4px 6px;
    border-radius: 4px;
    background: #e3f2fd;
    color: #1565c0;
    border: 1px solid #bbdefb;
}

.examples-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 6px;
}

.examples-list .example-link {
    text-decoration: none;
    color: #000; /* 見出し側は黒 */
    display: inline-block;
    font-weight: 700; /* ラベルを太字に */
}

.examples-list .example-link:hover {
    text-decoration: underline;
}

.examples-list .example-text {
    color: #757575; /* 具体例はグレー */
    font-weight: 400; /* 具体例は通常太さ */
}

.examples-bullet {
    font-size: 0.5em; /* ▶ を半分の大きさに */
    line-height: 1;
    margin-right: 6px;
}
