/* ========================================
   作品タイトルリンク (一時的にオフ)
======================================== */
/*
.item-title a {
    text-decoration: none;
    transition: text-decoration 0.2s ease;
}

.item-title a:hover {
    text-decoration: underline;
}
*/

/* ========================================
   サークル名リンクスタイル (一時的にオフ)
======================================== */
/*
.circle-link {
    color: #0052a3;
    text-decoration: none;
    transition: color 0.2s ease, text-decoration 0.2s ease;
}

.circle-link:hover {
    color: #0052a3;
    text-decoration: underline;
}
*/

/* サークル名テキスト（リンク無効時）*/
.circle-text {
    color: inherit;
}

/* ========================================
   サムネイルホバー効果
======================================== */
.thumbnail-image-wrapper {
    position: relative;
    cursor: zoom-in;
}

.thumbnail-image-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0);
    transition: background-color 0.3s ease;
    pointer-events: none;
}

.thumbnail-image-wrapper:hover::after {
    background-color: rgba(255, 255, 255, 0.3);
}

/* ========================================
   販売数表示コンテナ
======================================== */
.sales-display-container {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 6px;
    padding: 0;
    width: 100%;
}

/* ========================================
   販売数テキスト（シンプル表示）
======================================== */
.sales-text {
    font-size: 0.85rem;
    color: #666;
    font-weight: 400;
}

/* ========================================
   価格テーブル（リスト形式）
======================================== */
.price-table {
    display: flex;
    flex-direction: column;
    gap: 0px;
    width: 100%;
}

/* 価格テーブル行（各サイト） */
.price-table-row {
    display: flex;
    align-items: center;
    gap: 0px;
    padding: 2px 0;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s ease;
}

.price-table-row:last-child {
    border-bottom: none;
}

.price-table-row:not(:first-child) {
    margin-top: -0px;
}

.price-table-row:hover {
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

/* サイトラベル列 */
.price-table-site {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    min-width: 60px;
    margin-left: 5px;
}

/* サイトラベル - 横幅固定 */
.site-label {
    display: inline-block;
    width: 53px;
    padding: 0px 0;
    border-radius: 8px;
    color: #ffffff;
    text-align: center;
    font-weight: 600;
    font-size: 0.75em;
}

/* Fanzaカラー */
.site-label.fanza {
    background: linear-gradient(135deg, #e53935 0%, #c62828 100%);
}

/* DLSiteカラー */
.site-label.dlsite {
    background: linear-gradient(135deg, #4a90e2 0%, #357abd 100%);
}

/* 価格コンテンツ列 */
.price-table-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* 価格メイン行（セール価格 + 割引バッジ） */
.price-main-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 価格サブ行（通常価格・打ち消し線） */
.price-sub-row {
    display: flex;
    align-items: center;
}

/* 定価（グレー・打ち消し線） */
.original-price {
    text-decoration: line-through;
    color: #757575;
    font-size: 0.9em;
    font-weight: 500;
    line-height: 1.2;
    margin-bottom: 2px;
}

/* 割引率バッジ（吹き出しスタイル） */
.discount-badge {
    display: inline-block;
    position: relative;
    background-color: #bf80ff;
    color: #ffffff;
    font-size: 0.7em;
    font-weight: bold;
    padding: 0px 4px;
    border-radius: 4px;
    margin-left: 6px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* 吹き出しの尻尾（左向き） */
.discount-badge::before {
    content: '';
    position: absolute;
    left: -5px;
    top: calc(50% + 1px);
    transform: translateY(-50%);
    border-width: 5px 5px 5px 0;
    border-style: solid;
    border-color: transparent #bf80ff transparent transparent;
}

/* セール価格（赤・太字 - 最重要） */
.sale-price {
    color: #d32f2f;
    font-weight: bold;
    font-size: 1.2em;
    text-shadow: 0 1px 3px rgba(211, 47, 47, 0.2);
    letter-spacing: 0.3px;
    line-height: 0;
    margin-bottom: 1px;
}

/* 通常価格（ダークグレー） */
.regular-price {
    color: #424242;
    font-size: 1.1em;
    font-weight: 700;
    line-height: 1.3;
}

/* 未販売表示 */
.not-available {
    color: #999;
    font-size: 0.9em;
    font-style: italic;
}

/* ========================================
   レスポンシブ対応
======================================== */
@media (max-width: 768px) {
    .sales-display-container {
        flex-direction: column;
    }

    .sales-box {
        max-width: 100%;
    }

    .thumbnail-area {
        width: 100%;
    }

    .thumbnail-image-wrapper {
        width: 100%;
        height: auto;
        aspect-ratio: 4 / 3;
    }

    .price-table-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .price-table-site {
        width: 100%;
    }

    .site-label {
        width: auto;
    }

    .price-table-content {
        width: 100%;
    }
}

/* ========================================
   画像モーダル
======================================== */
.image-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    cursor: pointer;
}

.image-modal-content {
    position: relative;
    z-index: 10000;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.image-modal-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: rgba(60, 60, 60, 0.6);
    border: none;
    color: transparent;
    font-size: 42px;
    cursor: pointer;
    padding: 0;
    width: 50px;
    height: 50px;
    transition: all 0.2s ease;
    font-weight: 300;
    border-radius: 6px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.image-modal-close::after {
    content: '×';
    display: block;
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, calc(-50% - 2px));
    z-index: 2;
}

.image-modal-close::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0);
    transition: background 0.2s ease;
    pointer-events: none;
    z-index: 1;
}

.image-modal-close:hover::before {
    background: rgba(255, 255, 255, 0.3);
}

.image-modal-close:active::before {
    background: rgba(255, 255, 255, 0);
}

.image-modal-body {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 20px;
    position: relative;
}

.gallery-image-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.image-modal-body img {
    max-width: 80vw;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    cursor: zoom-in;
}

/* 共通ナビゲーションボタンスタイル */
.nav-btn-common {
    background: rgba(60, 60, 60, 0.6);
    color: white;
    border: none;
    width: 44px;
    height: 100px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: all 0.2s ease;
    font-size: 1.5rem;
    position: relative;
    overflow: hidden;
}

.nav-btn-common::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0);
    transition: background 0.2s ease;
    pointer-events: none;
}

.nav-btn-common:hover::before {
    background: rgba(255, 255, 255, 0.3);
}

.nav-btn-common:active::before {
    background: rgba(255, 255, 255, 0);
}

/* 詳細画面のボタン用の追加スタイル */
.slide-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}

/* モーダルのボタン用の追加スタイル（特になし） */

.gallery-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    transform: none;
}

.gallery-indicator {
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}

.image-modal-info {
    color: white;
    text-align: center;
    max-width: 600px;
}

.image-modal-info h3 {
    font-size: 20px;
    margin: 0 0 8px 0;
    font-weight: 600;
}

.image-modal-info p {
    font-size: 16px;
    color: #ccc;
    margin: 0;
}

@media (max-width: 768px) {
    .image-modal-body {
        flex-direction: column;
        gap: 10px;
    }

    .image-modal-body img {
        max-width: 90vw;
        max-height: 55vh;
    }

    .image-modal-close {
        font-size: 36px;
        top: -45px;
    }

    .image-modal-info h3 {
        font-size: 16px;
    }

    .image-modal-info p {
        font-size: 14px;
    }

    .gallery-nav {
        width: 45px;
        height: 45px;
        font-size: 20px;
    }

    .gallery-image-container {
        order: 2;
    }

    .gallery-nav-prev {
        order: 1;
    }

    .gallery-nav-next {
        order: 3;
    }
}
