/* GIRLページ固有のスタイル */

/* GIRL用バウンス（グレー→ピンク） */
#girl .title-bounce {
    animation: textBounceGrey 4s ease-in-out infinite;
}

#girl .title-bounce:nth-child(1) { animation-delay: 0s; }
#girl .title-bounce:nth-child(2) { animation-delay: 0.4s; }
#girl .title-bounce:nth-child(3) { animation-delay: 0.8s; }
#girl .title-bounce:nth-child(4) { animation-delay: 1.2s; }

/* GIRL セクション */
#girl {
    height: auto;
    min-height: 1200px;
    padding-top: 130px;
    padding-bottom: 100px;
    justify-content: flex-start;
    position: relative;
    overflow: hidden;
}

#girl h2 {
    color: #6e6e6e;
    position: relative;
    z-index: 2;
    font-weight: 300;
    -webkit-text-stroke: 5px #ffffff;
    text-stroke: 5px #ffffff;
    paint-order: stroke fill;
}

#girl h2::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, 5px);
    width: 1182px;
    height: 15px;
    background: linear-gradient(90deg,
        #ffcfe3 0%,
        #eaeaff 40%,
        #eaeaff 60%,
        #ffcfe3 100%);
    background-size: 200% 100%;
    border-radius: 5px;
    z-index: -1;
    animation: borderGradientFlow 10s ease-in-out infinite;
}

/* GIRLページ用: 横4枚×縦2列のグリッドレイアウト */
#girl .schedule-images {
    display: grid;
    grid-template-columns: repeat(4, 280px);
    gap: 20px;
    margin-top: 50px;
    width: 1180px;
    margin-left: calc(50% - 590px - 1px);
    margin-right: auto;
}

/* GIRLページ専用のパララックスフェードイン */
#girl .schedule-card.parallax-fade {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

#girl .schedule-card.parallax-fade.visible {
    opacity: 1;
    transform: translateY(0);
}

.schedule-images img {
    display: block;
    width: 280px;
}

.schedule-card {
    position: relative;
    width: 280px;
    height: 550px;
    background-image: url('../images/schedulecard_bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: block;
    text-decoration: none;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

/* カード縁アニメーション用Canvas */
.card-border-canvas {
    position: absolute;
    top: -4px;
    left: -4px;
    width: 288px;
    height: 558px;
    z-index: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* カード全体のホバー時に縁アニメーションを表示（デフォルト） */
.schedule-card:hover .card-border-canvas {
    opacity: 1;
}

/* マルチカードは手動制御（JavaScriptで制御） */
/* デフォルトの縁アニメーションは非表示（JavaScriptでshow-borderクラスを制御） */
.schedule-card-multi .card-border-canvas {
    opacity: 0;
}

/* マルチカードで縁アニメーション表示クラス */
.schedule-card-multi.show-border .card-border-canvas {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* 画像エリアホバー時は強制的に非表示 */
.schedule-card-multi.image-hover .card-border-canvas {
    opacity: 0 !important;
    transition: none !important;
}

.schedule-card img {
    display: block;
    width: 280px;
}

/* マルチ画像カルーセル用 */
.multi-image-container {
    position: relative;
    width: 280px;
    height: 280px;
    pointer-events: auto; /* 画像エリアは独立したホバー判定 */
    z-index: 10; /* カード本体より上に配置 */
}

/* ポップアップ表示中は画像カルーセルを無効化 */
.schedule-card.popup-active .multi-image-container {
    pointer-events: none;
}

.multi-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 280px;
    height: 280px;
    object-fit: cover;
    transition: transform 0.4s ease, opacity 0.4s ease;
    cursor: grab;
    pointer-events: auto;
    z-index: 5;
    opacity: 0.6;  /* 奥の画像は80%透過 */
}

.multi-img:active {
    cursor: grabbing;
}

/* デフォルト状態: すべて中央に重なる */
.multi-img-left,
.multi-img-right {
    z-index: 6;
    opacity: 0.6;  /* 奥の画像は80%透過 */
}

.multi-img-center {
    z-index: 7;
    opacity: 1;  /* 手前の画像は透過なし */
}

/* 画像エリアホバー時のみ: 左右の画像が飛び出す（20%縮小） */
.schedule-card-multi .multi-image-container:hover .multi-img-left {
    transform: translateX(-60px) scale(0.8);
}

.schedule-card-multi .multi-image-container:hover .multi-img-center {
    transform: scale(1);
}

.schedule-card-multi .multi-image-container:hover .multi-img-right {
    transform: translateX(60px) scale(0.8);
}

/* 星が飛び出すアニメーション（非表示） */
.burst-star {
    display: none;
}

/* 電光掲示板アニメーション */
.led-text-container {
    position: absolute;
    top: 90%;
    left: 0;
    width: 100%;
    height: 60px;
    transform: translateY(-50%);
    overflow: hidden;
    pointer-events: none;
    z-index: 10;  /* 画像の上に表示 */
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* 画像エリアホバー時のみ電光掲示板を非表示 */
.schedule-card-multi .multi-image-container:hover .led-text-container {
    opacity: 0;
}

.led-text {
    position: absolute;
    white-space: nowrap;
    font-family: Impact, 'Arial Black', sans-serif;
    font-weight: 900;
    /* ★サイズ設定★ ここでフォントサイズを調整できます */
    font-size: 50px;
    /* ★カラー設定★ ここで色を変更できます */
    color: #fa85bfd7;
    animation: ledScroll 8s linear infinite, ledBlink 0.8s ease-in-out infinite;
    letter-spacing: 1px;
    text-transform: uppercase;
    /* ドット感を出すためのフィルター */
    filter: contrast(2) brightness(1.2);
}

/* カード2専用の電光掲示板カラー */
.schedule-card-multi-2 .led-text {
    /* ★カード2のカラー設定★ ここで色を変更できます */
    color: #6a8acfd7;  /* カード2は青色 */
}

/* カード4専用の電光掲示板カラー */
.schedule-card-multi-4 .led-text {
    /* ★カード4のカラー設定★ ここで色を変更できます */
    color: #6a8acfd7;  /* カード4は青色 */
}

@keyframes ledScroll {
    0% {
        transform: translateX(100%) scaleY(1.2);
    }
    100% {
        transform: translateX(-100%) scaleY(1.2);
    }
}

@keyframes ledBlink {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.3;
    }
}

.schedule-card-text {
    position: absolute;
    top: 0;
    left: 0;
    width: 280px;
    height: 48px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 16px;
    color: #6e6e6e;
    z-index: 2;
    pointer-events: auto;  /* クリック可能に */
    cursor: pointer;
    animation: textBlink 0.8s ease-in-out infinite;
}

@keyframes textBlink {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.1;
    }
}

.schedule-card-girl-image {
    position: absolute;
    top: 48px;
    left: 50%;
    transform: translateX(-50%);
    width: 234px;
    height: 320px;
    background-color: #f0f0f0;
    z-index: 1;
}

.schedule-card-girl-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.schedule-card-info {
    position: absolute;
    top: 48px;
    left: 0;
    width: 280px;
    height: 502px;
    display: flex;
    flex-direction: column;
    align-items: center;
    pointer-events: none;  /* クリックを画像に通す */
    z-index: 2;
}

.schedule-card-name {
    position: absolute;
    top: 332px;
    width: 234px;
    font-family: "Yu Mincho", "YuMincho", serif;
    color: #6e6e6e;
    text-align: center;
    pointer-events: auto;  /* クリック可能に */
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
}

.schedule-card-name.marquee {
    text-align: left;
}

.schedule-card-name .marquee-inner {
    display: inline-block;
    animation: marqueeScroll 12s linear infinite;
}

@keyframes marqueeScroll {
    0% { transform: translateX(0); }
    35% { transform: translateX(0); }
    65% { transform: translateX(-50%); }
    100% { transform: translateX(-50%); }
}

.schedule-card-name .name-main {
    font-size: 30px;
    display: inline-block;
    position: relative;
}

/* カード全体ホバー時のname-mainアニメーション用の擬似要素 */
.schedule-card-name .name-main::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    transform: scale(1);
    pointer-events: none;
}

/* JavaScriptで制御するため、クラスベースに変更 */
.schedule-card-name .name-main.zoom-active::before {
    animation: zoomFadeOut 0.5s ease forwards;
}

@keyframes zoomFadeOut {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

.schedule-card-name .name-age {
    font-size: 14px;
}

.schedule-card-size {
    position: absolute;
    top: 379px;
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 13px;
    color: #6e6e6e;
    text-align: center;
    pointer-events: auto;  /* クリック可能に */
    cursor: pointer;
}

.schedule-card-time {
    position: absolute;
    top: 414px;
    width: 234px;
    height: 38px;
    background-color: #f8a5c8;
    border-radius: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 17px;
    color: #ffffff;
    pointer-events: auto;  /* クリック可能に */
    cursor: pointer;
    gap: 6px; /* アイコンとテキストの間隔 */
}

/* 時計アイコン（FontAwesome） */
.schedule-card-time::before {
    content: '\f017';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 17px;
    display: inline-block;
    flex-shrink: 0;
}

/* 時間未登録時はアイコン非表示 */
.schedule-card-time.no-time::before {
    display: none;
}

/* カード2と4の青色バージョン */
.schedule-card-time-blue {
    background-color: #8cbaff;
}

.schedule-card-fee {
    position: absolute;
    top: 463px;
    width: 234px;
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 16px;
    color: #6e6e6e;
    text-align: center;
    pointer-events: auto;  /* クリック可能に */
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
}

.schedule-card-fee.marquee {
    text-align: left;
}

.schedule-card-fee .marquee-inner {
    display: inline-block;
    animation: marqueeScroll 12s linear infinite;
}

.schedule-view-more {
    position: absolute;
    top: calc(155px + 32px + 50px + 550px + 17px);
    right: calc(50% - 590px);
    font-family: 'Times New Roman', Times, serif;
    font-size: 20px;
    color: #6e6e6e;
    text-decoration: none;
    display: inline-block;
    animation: viewMoreBlink 1.5s ease-in-out infinite;
}

/* ====================================
   GIRLページ レスポンシブ
   ==================================== */
@media screen and (max-width: 1024px) {
    #girl {
        padding-top: 80px;
        padding-bottom: 60px;
        min-height: auto;
    }

    #girl h2::before {
        width: 90%;
    }

    #girl .schedule-images {
        width: 90%;
        margin-left: auto;
        margin-right: auto;
        grid-template-columns: repeat(4, 280px);
        justify-content: center;
    }

    .schedule-view-more {
        position: relative;
        top: auto;
        right: auto;
        margin-top: 20px;
        align-self: flex-end;
        margin-right: 5%;
    }
}

@media screen and (max-width: 768px) {
    #girl {
        padding-top: 50px;
        padding-bottom: 40px;
    }

    #girl h2::before {
        width: 95%;
    }

    #girl .schedule-images {
        width: 95%;
        grid-template-columns: repeat(2, 280px);
        justify-content: center;
    }

    .schedule-view-more {
        margin-right: 2.5%;
    }
}

@media screen and (max-width: 620px) {
    #girl .schedule-images {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .schedule-card {
        width: 100%;
        height: auto;
        aspect-ratio: 280 / 550;
        background-size: 100% 100%;
    }

    .schedule-card-text {
        width: 100%;
        height: calc(48 / 550 * 100%);
        font-size: 14px;
    }

    .schedule-card-girl-image {
        width: 83.57%;
        height: calc(320 / 550 * 100%);
        top: calc(48 / 550 * 100%);
    }

    .multi-image-container {
        width: 100%;
        height: 0;
        padding-bottom: 100%;
    }

    .multi-img {
        width: 100%;
        height: 100%;
    }

    .schedule-card-info {
        width: 100%;
        height: calc(502 / 550 * 100%);
        top: calc(48 / 550 * 100%);
    }

    .schedule-card-name {
        top: calc(332 / 502 * 100%);
        width: 83.57%;
    }

    .schedule-card-name .name-main {
        font-size: 22px;
    }

    .schedule-card-name .name-age {
        font-size: 12px;
    }

    .schedule-card-size {
        top: calc(379 / 502 * 100%);
        font-size: 11px;
    }

    .schedule-card-time {
        top: calc(414 / 502 * 100%);
        width: 83.57%;
        height: calc(38 / 550 * 100%);
        font-size: 14px;
    }

    .schedule-card-fee {
        top: calc(463 / 502 * 100%);
        width: 83.57%;
        font-size: 13px;
    }

    .card-border-canvas {
        width: calc(100% + 8px);
        height: calc(100% + 8px);
    }

    .led-text {
        font-size: 32px;
    }

    .led-text-container {
        height: 40px;
    }
}

/* 検索フィルター */
.girl-search-container {
    width: 1180px;
    margin: 40px auto 30px;
    padding: 25px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 10px;
    position: relative;
    z-index: 2;
}

.girl-search-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 10px;
    padding: 3px;
    background: linear-gradient(135deg, rgba(248, 165, 200, 0.5) 0%, rgba(157, 174, 228, 0.5) 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
}

.girl-search-box {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.search-input,
.search-select {
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 16px;
    padding: 10px 15px;
    border: 2px solid rgba(248, 165, 200, 0.3);
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.9);
    color: #333333;
    transition: all 0.3s ease;
}

.search-input {
    flex: 1;
    min-width: 250px;
}

.search-input:focus,
.search-select:focus {
    outline: none;
    border-color: rgba(248, 165, 200, 0.8);
    box-shadow: 0 0 8px rgba(248, 165, 200, 0.4);
}

.search-reset {
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 16px;
    padding: 10px 30px;
    border: 2px solid rgba(157, 174, 228, 0.5);
    border-radius: 5px;
    background: rgba(157, 174, 228, 0.2);
    color: #333333;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-reset:hover {
    background: rgba(157, 174, 228, 0.4);
    border-color: rgba(157, 174, 228, 0.8);
    transform: translateY(-2px);
}

.girl-search-stats {
    margin-top: 15px;
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 14px;
    color: #666666;
    text-align: center;
}

/* ページネーション */
.girl-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 40px auto 20px;
    flex-wrap: wrap;
}

.pagination-btn {
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 16px;
    padding: 8px 15px;
    border: 2px solid rgba(248, 165, 200, 0.3);
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.8);
    color: #333333;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pagination-btn:hover:not(.active):not(:disabled) {
    background: rgba(248, 165, 200, 0.2);
    border-color: rgba(248, 165, 200, 0.6);
    transform: translateY(-2px);
}

.pagination-btn.active {
    background: linear-gradient(135deg, rgba(248, 165, 200, 0.7) 0%, rgba(157, 174, 228, 0.7) 100%);
    border-color: rgba(248, 165, 200, 0.8);
    color: #ffffff;
    font-weight: bold;
}

.pagination-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.pagination-info {
    font-family: "Yu Mincho", "YuMincho", serif;
    font-size: 14px;
    color: #666666;
    padding: 0 10px;
}

/* カード非表示用 */
.schedule-card.hidden {
    display: none !important;
}

/* レスポンシブ対応 */
@media screen and (max-width: 1024px) {
    .girl-search-container {
        width: 90%;
    }
}

@media screen and (max-width: 768px) {
    .girl-search-container {
        width: 95%;
        padding: 20px;
    }

    .girl-search-box {
        flex-direction: column;
        gap: 10px;
    }

    .search-input,
    .search-select,
    .search-reset {
        width: 100%;
        font-size: 14px;
    }

    .search-input {
        min-width: 100%;
    }

    .pagination-btn {
        font-size: 14px;
        padding: 6px 12px;
    }

    .pagination-info {
        font-size: 12px;
        width: 100%;
        text-align: center;
    }
}

@media screen and (max-width: 480px) {
    .girl-search-container {
        padding: 15px;
    }

    .search-input,
    .search-select,
    .search-reset {
        font-size: 13px;
        padding: 8px 12px;
    }

    .pagination-btn {
        font-size: 12px;
        padding: 5px 10px;
    }
}
