﻿/* 手機版 */
@media (max-width: 575.98px) {
    .d-flex.flex-column.flex-md-row {
        flex-direction: column !important;
        gap: 8px !important;
    }

    .date-range {
        display: flex;
        flex-direction: column;
        gap: 8px;
        border: none !important;
        background-color: transparent !important;
    }

    .date-wrapper {
        border: 1px solid #68442b;
        border-radius: 6px;
        background-color: #FFF;
        padding: 0 10px;
        height: 39.5px;
        position: relative;
    }

    .date-separator {
        display: none !important;
    }

    .date-wrapper .date-display {
        justify-content: start !important;
        padding-left: 12px !important;
    }

    .kshist-detail-wrapper {
        background-image: none !important;
    }
    .house-arrow.left {
        left: 0% !important;
    }

    .house-arrow.right {
        left: 13.3% !important;
    }
}

@media (min-width: 576px) and (max-width: 767.98px) {
    .d-flex.flex-column.flex-md-row {
        flex-direction: column !important; /* 父容器垂直排列 */
        gap: 8px !important; /* 元素間距 */
    }

    /* 日期容器調整成獨立邊框 */
    .date-range {
        flex-direction: column; /* 垂直排列 */
        gap: 8px !important;
        border: none !important;
        background-color: transparent !important;
    }

    .date-wrapper {
        border: 1px solid #68442b;
        border-radius: 6px;
        background-color: #FFF;
        padding: 0 10px;
        height: 39.5px;
        position: relative;
    }

    .date-separator {
        display: none !important; /* 手機版不用 ~ */
    }

    .date-wrapper .date-display {
        justify-content: start !important;
        padding-left: 12px !important;
    }
    .kshist-detail-wrapper {
        background-image: none !important;
    }

    .house-arrow.left {
        left: 0% !important;
    }

    .house-arrow.right {
        left: 9.5% !important;
    }
}
/* 大平板 */
@media (min-width: 768px) and (max-width: 991.98px) {
    .d-flex.flex-column.flex-md-row {
        flex-direction: column !important; /* 父容器垂直排列 */
        gap: 8px !important; /* 元素間距 */
    }

    /* 日期容器調整成獨立邊框 */
    .date-range {
        flex-direction: column; /* 垂直排列 */
        gap: 8px !important;
        border: none !important;
        background-color: transparent !important;
    }

    .date-wrapper {
        border: 1px solid #68442b;
        border-radius: 6px;
        background-color: #FFF;
        padding: 0 10px;
        height: 39.5px;
        position: relative;
    }

    .date-separator {
        display: none !important; /* 手機版不用 ~ */
    }

    .date-wrapper .date-display {
        justify-content: start !important;
        padding-left: 12px !important;
    }

    .house-arrow.left {
        left: 0% !important;
    }

    .house-arrow.right {
        left: 7.5% !important;
    }
    .kshist-detail-wrapper {
        background-position: 0% 25% !important;
        background-size: 55% 48% !important;
    }
}
/* 小桌機*/
@media (min-width: 992px) and (max-width: 1199.98px) {
    .kshist-detail-wrapper {
        background-position: 0% 25% !important;
        background-size: 55% 48% !important;
    }
}
/* 特大桌機尺寸 */
@media (min-width: 1200px) and (max-width: 1400px) {
    .kshist-detail-wrapper {
        background-position: 0% 25% !important;
        background-size: 55% 48%!important;
    }
}
/*.kshist-detail-wrapper {
    position: relative;*/
    /* 背景圖 */
    /*background-image: url('../images/kshist_bg_top.png');
    background-repeat: no-repeat;
    background-position: 0% 23%;*/ /* 可調整相對位置 */
    /*background-size: 55% auto;*/ /* 固定寬度，高度自動 */
/*}*/
.kshist-bg1 {
    position: absolute;
    pointer-events: none;
    width: 670px; /* 固定寬度 */
    left: -190px; /* 固定左邊距 */
    top: 250px; /* 固定上邊距 */
    z-index: -1;
    max-width: 670px; /* 避免 container 縮小時自動縮放 */
}
.kshist-info {
    width: 300px;
}
.intro-card {
    background-color: transparent;
    border: none;
}

/* 隱藏原生日期 icon */
input[type="date"]::-webkit-calendar-picker-indicator {
    opacity: 0;
    position: absolute;
    right: 0;
    cursor: pointer;
}

/* 容器 */
.date-wrapper {
    position: relative;
    width: 100%;
    height: 39.5px;
}

    /* 隱藏原生 input 文字 */
    .date-wrapper input[type="date"] {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        opacity: 0;
        border: none;
        /*        cursor: pointer;*/
        color: transparent;
        background-color: transparent;
    }

    /* 自訂顯示文字 */
    .date-wrapper .date-display {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #C3AD9C !important;
        letter-spacing: 3px;
        padding-right: 20px;
    }

    /* calendar icon */
    .date-wrapper i {
        position: absolute;
        right: 10px;
        top: 50%;
        transform: translateY(-50%);
        pointer-events: none;
        color: #C3AD9C !important;
    }

/* 日期範圍整體 */
.date-range {
    display: flex;
    border: 1px solid #68442b;
    border-radius: 6px;
    background-color: #FFF;
    overflow: hidden;
}

/* 分隔符 */
.date-separator {
    padding: 0 8px;
    color: #C3AD9C !important;
    font-weight: bold;
    user-select: none;
}

.hidden-inputs {
    position: absolute;
    opacity: 0;
    pointer-events: none;
    height: 0;
    overflow: hidden;
}

.lang-toggle {
    display: inline-block;
    position: relative;
    width: 160px;
    height: 30px;
}

    .lang-toggle input {
        display: none;
    }

    .lang-toggle label {
        display: flex;
        align-items: center;
        justify-content: space-between;
        background-color: white;
        border-radius: 10px;
        padding: 0;
        cursor: pointer;
        height: 100%;
        border: 1px solid #C3AD9C;
        overflow: hidden;
    }

.lang-option {
    width: 50%;
    text-align: center;
    line-height: 40px;
    font-size: 0.875rem;
    font-weight: bold;
    color: #C3AD9C !important;
    background-color: white;
    transition: all 0.2s ease;
}

/* 點選時切換樣式 */
input:not(:checked) + label .lang-zh {
    background-color: #68442b;
    color: white !important;
}

input:checked + label .lang-en {
    background-color: #68442b;
    color: white !important;
}

.polygon-wrapper {
    position: relative;
    width: 400px;
    height: 300px;
    margin: auto;
}

.pentagon-img {
    clip-path: polygon(50% 0, 34% 0, 100% 25%, 100% 80%, 0 80%, 0 22%);
    -webkit-clip-path: polygon(44% 13%, 44% 13%, 95% 33%, 95% 87%, 7% 87%, 7% 28%);
    object-fit: cover;
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 2;
}

.pentagon-underlay {
    position: absolute;
    top: 7%;
    left: 3%;
    width: 88%;
    height: 70%;
    z-index: 1;
}

.house-carousel {
    width: 750px;
    height: 400px;
    overflow: hidden;
    position: relative;
    border-radius: 5px;
}

.house-carousel-img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* 保持圖片比例並填滿容器，可能裁切 */
    display: block;
    margin: 0 auto;
}

.house-carousel-wrapper {
    position: relative;
    display: flex;
    align-items: center; /* 垂直置中 */
    justify-content: center; /* 水平置中 */
}

.house-arrow {
    position: absolute;
    bottom: -45px;
    transform: translateY(-50%);
    font-size: 2rem;
    color: #FFF;
    cursor: pointer;
    z-index: 10;
}

    .house-arrow.left {
        left: 14%; /* 可依需要調整 */
        background-color: #8fcac3;
        border-radius: 5px;
        width: 50px;
        padding: 8px 15px;
    }

    .house-arrow.right {
        left: 18.7%; /* 可依需要調整 */
        background-color: #8fcac3;
        border-radius: 5px;
        width: 50px;
        padding: 8px 15px;
    }
