/* 基本的なリセットとベーススタイル */
body,
h1,
h2,
h3,
h4,
p,
div,
form,
label,
input,
button,
span {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    /* font-family: sans-serif; /* より具体的なフォントを指定推奨 */
}

body {
    font-family: 'Noto Sans JP', 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
    line-height: 1.6;
    background-color: #f8f9fa;
    /* 少し明るい背景色 */
    color: #343a40;
    /* 基本の文字色 */
    display: flex;
    flex-direction: column;
    /* ヘッダーやフッターがある場合に備えて */
    align-items: center;
    min-height: 100vh;
    padding: 20px 10px;
    padding-top: 20px;
    /* 固定要素がなくなるため、通常のパディングに戻す */
}

/* トップロゴコンテナ */
.top-logo-container {
    position: relative;
    /* 固定を解除 */
    text-align: center;
    padding: 10px 0;
    /* 上下の余白を減らす */
    /* background-color: #f8f9fa; /* 背景色 */
    /* box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05); /* 軽い影 */
    margin-bottom: 20px;
    /* ロゴの下に余白を追加 */
}

.top-logo-container .top-logo {
    height: 45px;
    /* ロゴの高さ。必要に応じて調整してください */
    width: auto;
    /* アスペクト比を維持 */
}

/* Progress bar container */
.progress-bar-container {
    margin-bottom: 20px;
    /* プログレスバーの下に余白を追加 */
}

.container {
    background-color: #ffffff;
    padding: 25px 30px;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
    width: 100%;
    max-width: 960px;
    /* Wider layout, common Bootstrap container size */
    /* コンテンツの最大幅を少し広めに */
    margin-bottom: 30px;
    margin-top: 20px;
}

/* 見出しスタイル */
h1,
h2,
h3 {
    color: #2c3e50;
    /* 見出し用の濃い色 */
    margin-bottom: 25px;
    text-align: center;
    font-weight: 600;
}

h1 {
    font-size: 2.2em;
    /* 28px相当 (16pxベースの場合) */
    margin-bottom: 30px;
}

h2 {
    font-size: 1.8em;
    /* 24px相当 */
}

h3 {
    font-size: 1.5em;
    /* 20px相当 */
    text-align: left;
    /* 通常のh3は左寄せに */
}

.container>h3:first-of-type {
    /* コンテナ直下の最初のh3 (例: カレンダーの年月表示) */
    text-align: center;
}


/* フォーム要素のスタイル */
form div {
    margin-bottom: 18px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    /* 少し太く */
    color: #495057;
    font-size: 0.95em;
}

input[type="text"],
input[type="number"],
input[type="email"],
input[type="date"],
input[type="tel"],
select,
textarea,
.flatpickr-input {
    /* Flatpickrの入力フィールドにもスタイルを適用 */
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ced4da;
    border-radius: 5px;
    font-size: 1em;
    /* Flatpickrはinput[type=text]になるのでfont-sizeを継承 */
    transition: border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

input[type="text"]:focus,
input[type="number"]:focus,
input[type="email"]:focus,
input[type="date"]:focus,
input[type="tel"]:focus,
select:focus,
textarea:focus,
.flatpickr-input:focus {
    border-color: #80bdff;
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

textarea {
    resize: vertical;
    /* 垂直方向のみリサイズ可能に */
    min-height: 90px;
    /* 最小の高さを設定 */
    line-height: 1.5;
    /* 行間を調整して読みやすく */
}

input[type="date"] {
    appearance: none;
    position: relative;
    -webkit-appearance: none;
    /* iOSでのデフォルトスタイル解除のため残す場合あり */
    background-color: #fff;
    /* 背景色を明示 */
    /* スマホでのタップエリアを確保しつつ、見た目を整える */
    min-height: 45px;
    /* ある程度の高さを確保 */
}

select {
    appearance: none;
    /* ブラウザデフォルトの矢印を消す */
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23343a40'%3E%3Cpath d='M7 10l5 5 5-5H7z'/%3E%3Csvg%3E");
    /* カスタム矢印 */
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 1em;
    padding-right: 40px;
    /* 矢印のスペースを確保 */
}

/* Flatpickrの入力フィールドの見た目を調整 */
.flatpickr-input {
    background-color: #fff;
    /* 背景色を明示 */
    cursor: pointer;
    /* クリック可能であることを示す */
    min-height: 45px;
    /* 他の入力フィールドと高さを合わせる */
    line-height: normal;
    /* placeholderが中央に来るように */
}

/* 人数選択UI */
.form-group-number {
    margin-bottom: 18px;
}

.form-group-number label {
    display: block;
    margin-bottom: 8px;
}

.number-input-group {
    display: flex;
    align-items: center;
}

.number-input-group input[type="number"] {
    width: 60px;
    /* 幅を固定 */
    text-align: center;
    border-left: none;
    border-right: none;
    border-radius: 0;
    margin: 0;
    -moz-appearance: textfield;
    /* Firefoxでのスピナー非表示 */
}

.number-input-group input[type="number"]::-webkit-outer-spin-button,
.number-input-group input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    /* Chrome, Safari, Edgeでのスピナー非表示 */
    margin: 0;
}

.number-input-button {
    width: 40px;
    height: 45px;
    /* input[type=date]の高さと合わせるイメージ */
    padding: 0;
    font-size: 1.5em;
    line-height: 45px;
    text-align: center;
    background-color: #e9ecef;
    border: 1px solid #ced4da;
    cursor: pointer;
    color: #495057;
    margin: 0;
    /* ボタン自体のマージンをリセット */
    display: inline-flex;
    /* 中央揃えのため */
    justify-content: center;
    align-items: center;
}

.number-input-button:first-of-type {
    border-top-left-radius: 5px;
    border-bottom-left-radius: 5px;
}

.number-input-button:last-of-type {
    border-top-right-radius: 5px;
    border-bottom-right-radius: 5px;
}

.number-input-button:hover {
    background-color: #dee2e6;
}


/* ボタンの共通スタイル */
button,
input[type="submit"] {
    background-color: #007bff;
    /* プライマリカラー (Bootstrap風) */
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.05em;
    font-weight: 500;
    transition: background-color 0.2s ease, transform 0.1s ease;
    display: block;
    width: 100%;
    margin-top: 15px;
}

/* 人数変更ボタンは共通スタイルから一部除外 */
.number-input-button {
    width: 40px;
    /* 上書き */
    padding: 0;
    /* 上書き */
    margin-top: 0;
    /* 上書き */
    font-size: 1.5em;
    /* 上書き */
    background-color: #e9ecef;
    /* 上書き */
    border: 1px solid #ced4da;
    /* 上書き */
    color: #495057;
    /* 上書き */
}

.number-input-button:hover {
    background-color: #dee2e6;
    /* 上書き */
}

button:active,
input[type="submit"]:active {
    transform: translateY(1px);
    /* クリック時のフィードバック */
}

/* 検索条件表示エリア (calendar.html) */
.search-criteria {
    background-color: #e9ecef;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 25px;
    border: 1px solid #dee2e6;
}

.search-criteria h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.3em;
    text-align: left;
    color: #495057;
}

.search-criteria p {
    margin-bottom: 10px;
    font-size: 1em;
    color: #212529;
}

.search-criteria p span {
    font-weight: 500;
    color: #007bff;
}

.search-criteria button {
    background-color: #28a745;
    /* 成功・変更ボタンの色 (緑系) */
    width: auto;
    display: inline-block;
    padding: 10px 20px;
    font-size: 0.95em;
    margin-top: 5px;
}

.search-criteria button:hover {
    background-color: #1e7e34;
}

/* カレンダー (calendar.html) */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
    margin-bottom: 25px;
    border: 1px solid #e0e0e0;
    padding: 10px;
    border-radius: 6px;
    background-color: #fdfdff;
    /* グリッド背景 */
}

.calendar-header {
    font-weight: 600;
    text-align: center;
    padding: 12px 5px;
    background-color: #f1f3f5;
    border-radius: 4px;
    font-size: 0.9em;
    color: #495057;
}

.calendar-day {
    text-align: center;
    padding: 8px 5px;
    border: 1px solid #e9ecef;
    min-height: 70px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    /* 日付を上に、空室数を下に */
    align-items: center;
    font-size: 0.9em;
    border-radius: 4px;
    background-color: #fff;
    cursor: default;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.1s ease;
}

/* brタグは使わずCSSで調整 */
.calendar-day>*:first-child {
    /* 日付部分 */
    font-size: 1.1em;
    font-weight: 500;
    margin-bottom: 4px;
}

.calendar-day>*:last-child {
    /* 空室数または× */
    font-size: 0.85em;
    color: #6c757d;
}


.calendar-day:not(.unavailable):not(.calendar-header) {
    cursor: pointer;
}

.calendar-day:not(.unavailable):not(.calendar-header):hover {
    background-color: #e6f7ff;
    border-color: #7cc5ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
}

.calendar-day:not(.unavailable):not(.calendar-header)>*:last-child {
    /* 空室ありの場合の文字色 */
    color: #28a745;
    /* 緑色で空室数を強調 */
    font-weight: 500;
}


.calendar-day.unavailable {
    background-color: #f8f9fa;
    color: #adb5bd;
    cursor: not-allowed;
}

.calendar-day.unavailable:hover {
    background-color: #f8f9fa;
}

.calendar-day.unavailable>*:last-child {
    /* 満室(×)の文字色 */
    color: #dc3545;
    /* 赤色で満室を強調 */
    font-weight: bold;
}

.calendar-day.closed-day {
    /* 休館日専用スタイル */
    background-color: #e9ecef;
    color: #6c757d;
}

.calendar-day.closed-day>*:last-child {
    /* 休館日の文字色 */
    color: #6c757d;
    font-weight: normal;
}


/* 月移動ボタン (calendar.html) */
#prev_month_button,
#next_month_button {
    background-color: #6c757d;
    /* グレー系の色 */
    width: auto;
    padding: 10px 18px;
    margin: 0 8px;
    display: inline-block;
    font-size: 0.95em;
}

#prev_month_button:hover,
#next_month_button:hover {
    background-color: #545b62;
}

.container>p[style="text-align: center;"] {
    /* 月移動ボタンのコンテナpタグ */
    margin-top: 10px;
}


/* プラン選択 (plans.html) */
.search-summary {
    /* plans.html用 */
    background-color: #f8f9fa;
    padding: 15px 20px;
    border-radius: 6px;
    margin-bottom: 20px;
    border: 1px solid #e9ecef;
}

.search-summary h4 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.2em;
    color: #343a40;
    text-align: left;
}

.search-summary p {
    margin-bottom: 5px;
    font-size: 0.95em;
    color: #495057;
}

.plan {
    border: 1px solid #dee2e6;
    padding: 20px 25px;
    margin-bottom: 25px;
    border-radius: 6px;
    background-color: #fff;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.2s ease;
}

.plan:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.plan h4 {
    margin-top: 0;
    margin-bottom: 12px;
    color: #007bff;
    font-size: 1.4em;
    text-align: left;
}

/* 古いplan-imagesのスタイルは削除またはコメントアウト */
/*
.plan .plan-images {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
    border-radius: 4px;
    overflow: hidden;
}
.plan .plan-images img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    object-fit: cover;
    flex: 1 1 calc(33.333% - 10px);
    min-width: 120px;
}
*/

/* 新しいスライダースタイル */
.plan-image-slider-container {
    position: relative;
    width: 100%;
    max-width: 400px;
    /* スライダーの最大幅を調整してください */
    margin: 0 auto 15px auto;
    /* 中央寄せと下のマージン */
    overflow: hidden;
    border-radius: 6px;
    /* コンテナに角丸 */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.plan-image-slider-wrapper {
    display: flex;
    transition: transform 0.4s ease-in-out;
}

.plan-image-slide {
    min-width: 100%;
    box-sizing: border-box;
}

.plan-image-slide img {
    display: block;
    width: 100%;
    height: 200px;
    /* 高さを固定するか、アスペクト比で調整 */
    object-fit: cover;
    /* 画像がコンテナに合わせてトリミングまたはフィット */
}

.slider-nav-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    z-index: 10;
    border-radius: 4px;
    font-size: 1.1em;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.slider-nav-button:hover {
    opacity: 1;
}

.slider-nav-button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.slider-prev-button {
    left: 10px;
}

.slider-next-button {
    right: 10px;
}

.plan p {
    margin-bottom: 10px;
    font-size: 1em;
    color: #495057;
}

.plan p.total-price-label {
    /* 合計料金表示用のpタグ */
    margin-bottom: 15px;
}

.plan button {
    background-color: #28a745;
    margin-top: 10px;
    width: auto;
    display: inline-block;
    padding: 10px 22px;
    font-size: 1em;
}

.plan button:hover {
    background-color: #1e7e34;
}

#selected_date {
    font-weight: bold;
    color: #007bff;
}

.container>p>a {
    /* 「カレンダーに戻る」リンク */
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
}

.container>p>a:hover {
    text-decoration: underline;
}


/* 予約情報入力・確認 (booking.html, confirm.html) */
.plan-details,
.booking-summary {
    background-color: #f1f3f5;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 25px;
    border: 1px solid #e0e0e0;
}

.plan-details h3,
.booking-summary h3,
.booking-summary p strong {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.3em;
    text-align: left;
    color: #343a40;
}

.plan-details p,
.booking-summary p {
    margin-bottom: 10px;
    font-size: 1em;
    color: #212529;
}

.plan-details p span,
.booking-summary p span {
    font-weight: 500;
}

.booking-summary p strong {
    font-size: 1em;
    margin-bottom: 0;
    display: inline-block;
    width: 120px;
    /* ラベル幅を揃える */
}

button[onclick="history.back()"] {
    background-color: #6c757d;
    /* 戻るボタンの色 */
    margin-top: 15px;
}

button[onclick="history.back()"]:hover {
    background-color: #545b62;
}

/* 予約完了 (complete.html) */
#display_email_sent {
    font-weight: bold;
    color: #007bff;
}

.container>p {
    /* complete.htmlのメッセージpタグ */
    font-size: 1.1em;
    margin-bottom: 15px;
    text-align: center;
}


/* レスポンシブ対応 */
@media (max-width: 768px) {
    .container {
        padding: 20px 20px;
        margin-bottom: 20px;
    }

    h1 {
        font-size: 1.8em;
    }

    h2 {
        font-size: 1.4em;
    }

    h3 {
        font-size: 1.2em;
    }

    input[type="text"],
    input[type="number"],
    input[type="email"],
    input[type="date"],
    input[type="tel"],
    select,
    textarea,
    .flatpickr-input {
        /* Flatpickrにも適用 */
        font-size: 0.9em;
        padding: 10px 12px;
    }

    .number-input-group input[type="number"] {
        /* スマホでの入力フィールド幅調整 */
        width: 60px;
        font-size: 0.9em;
        /* 他のinputと合わせる */
        padding: 10px 5px;
        /* パディング調整 */
    }

    .number-input-button {
        /* スマホでのボタンサイズ調整 */
        width: 40px;
        height: 41px;
        /* input[type=date]の高さと合わせるイメージ */
        line-height: 41px;
        font-size: 1.2em;
    }


    .calendar-grid {
        gap: 4px;
        padding: 8px;
    }

    .calendar-day {
        padding: 6px 3px;
        font-size: 0.8em;
        min-height: 100px;
    }

    .calendar-header {
        padding: 10px 3px;
        font-size: 0.75em;
        min-height: 80px;
    }

    .booking-summary p strong {
        width: 100px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 15px 5px;
        font-size: 0.9em;
        /* 全体のフォントサイズを小さく */
    }

    .container {
        padding: 15px 15px;
        margin: 0 5px 20px 5px;
        max-width: calc(100% - 10px);
    }

    h1 {
        font-size: 1.6em;
        margin-bottom: 20px;
    }

    h2 {
        font-size: 1.3em;
    }

    h3 {
        font-size: 1.1em;
    }

    input[type="text"],
    input[type="number"],
    input[type="email"],
    input[type="date"],
    input[type="tel"],
    select,
    textarea,
    .flatpickr-input {
        /* Flatpickrにも適用 */
        font-size: 0.85em;
        padding: 10px 12px;
    }

    .number-input-group input[type="number"] {
        /* スマホでの入力フィールド幅調整 */
        width: 50px;
        font-size: 0.85em;
        /* 他のinputと合わせる */
        padding: 10px 5px;
        /* パディング調整 */
    }

    .number-input-button {
        /* スマホでのボタンサイズ調整 */
        width: 35px;
        height: 41px;
        /* input[type=date]の高さと合わせるイメージ */
        line-height: 41px;
        font-size: 1.1em;
    }


    .calendar-day {
        font-size: 0.7em;
        min-height: 90px;
        padding: 5px 2px;
    }

    .calendar-day>*:first-child {
        /* 日付部分 */
        font-size: 0.9em;
    }

    .calendar-day>*:last-child {
        /* 空室数または× */
        font-size: 0.75em;
    }

    .calendar-header {
        font-size: 0.65em;
        padding: 8px 2px;
        min-height: 75px;
    }

    .plan {
        padding: 15px;
    }

    .plan h4 {
        font-size: 1.1em;
    }

    .plan p {
        font-size: 0.85em;
    }

    .booking-summary p strong {
        display: block;
        /* スマホではラベルをブロック要素に */
        width: auto;
        margin-bottom: 3px;
    }

    .booking-summary p span {
        padding-left: 5px;
    }
}


.plan .plan-actions .detail-button {
    background-color: #17a2b8;
    /* 詳細ボタンの色 (info blue) */
}

.plan .plan-actions .detail-button:hover {
    background-color: #117a8b;
}

.plan .plan-actions .detail-button:disabled {
    background-color: #a0d3db;
    cursor: not-allowed;
}


/* plan_detail.html */
.plan-full-details {
    background-color: #fff;
    padding: 20px 25px;
    border-radius: 6px;
    margin-bottom: 25px;
    border: 1px solid #e0e0e0;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.plan-full-details h4 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.3em;
    color: #007bff;
    text-align: left;
}

.plan-full-details p {
    margin-bottom: 10px;
    font-size: 1em;
    line-height: 1.7;
}

.plan-full-details ul {
    list-style: disc;
    margin-left: 25px;
    margin-bottom: 20px;
    padding-left: 0;
}

.plan-full-details ul li {
    margin-bottom: 8px;
}

.plan-full-details .actions {
    margin-top: 25px;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.plan-full-details .actions button {
    width: auto;
    padding: 12px 25px;
    flex-grow: 1;
}

@media (min-width: 480px) {
    .plan-full-details .actions button {
        flex-grow: 0;
    }
}

/* booking_details.html のための追加スタイル */
.form-row {
    display: flex;
    gap: 20px;
    /* 要素間のスペース */
    margin-bottom: 18px;
}

.form-group-half {
    flex: 1;
    /* 利用可能なスペースを均等に分割 */
}

.form-group-half:last-child {
    /* margin-right: 0; */
    /* 最後の要素の右マージンは不要 */
}

/* カレンダーページ専用のコンテナスタイル */
.calendar-page-container {
    /* max-width: 95%; /* 画面幅に対して広めに設定 */
    /* max-width: 1200px; /* もしくは固定値で広めに設定 */
}

/* 空室カレンダーテーブル (availability_calendar.html) */
.calendar-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.calendar-controls h3 {
    /* style.cssの既存h3スタイルを継承しつつ調整 */
    margin: 0 15px;
    /* 左右にマージンを追加 */
    font-size: 1.6em;
    /* 少し大きめに */
    color: #343a40;
    text-align: center;
    /* 中央寄せ */
}

.month-nav-button {
    /* 月移動ボタンのスタイル */
    background-color: #6c757d;
    color: white;
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
}

.month-nav-button:hover {
    background-color: #545b62;
}

.availability-table-container {
    overflow-x: auto;
    /* 横に長い場合にスクロールバーを表示 */
    margin-bottom: 20px;
    border: 1px solid #dee2e6;
    /* テーブルコンテナに枠線 */
    border-radius: 6px;
}

#availability_table {
    width: 100%;
    /* min-width は JavaScript で動的に設定する */
    /* min-width: 2550px; */
    /* テーブル全体の最小幅を、列数と列幅に基づいて設定 */
    border-collapse: collapse;
    /* table-layout: fixed; はスマホ表示ではautoの方が柔軟な場合があるため、
       スマホ用のメディアクエリで auto に変更することも検討。
       ただし、sticky header との兼ね合いで fixed のままで良い場合もある。
       今回は fixed のままで調整を試みる。
    */
    table-layout: fixed;
    /* 列幅の計算を高速化 */
}

#availability_table th,
#availability_table td {
    border: 1px solid #e0e0e0;
    text-align: center;
    /* Default for th, td content if not overridden */
    padding: 0;
    /* Padding is handled by child elements or specific cell types */
    text-align: center;
    padding: 0;
    /* Padding is handled by specific cell types or child elements */
    font-size: 0.9em;
    /* Base font size for table cells */
    height: 50px;
    /* Fixed cell height */
    vertical-align: middle;
    /* セル内容を垂直方向に中央揃え */
}

#availability_table thead th {
    /* 日付ヘッダー */
    position: -webkit-sticky;
    /* Safari対応 */
    position: sticky;
    top: 0;
    z-index: 2;
    /* 部屋タイプ列ヘッダーより手前、左上セルより奥 */
    background-color: #f1f3f5;
    /* ヘッダー背景色 */
    font-weight: 600;
    min-width: 60px;
    /* スマホ向けに少し狭く */
    /* 日付と曜日が1行に収まるように少し広げる */
    padding: 10px 5px;
    /* Specific padding for date header cells */
    /* 日付セルの最小幅 (M/D表示と〇×記号を考慮) */
    white-space: nowrap;
    /* 日付と曜日が改行されないように */
    overflow: hidden;
    /*念のため、万が一はみ出た場合 */
    text-overflow: ellipsis;
    /*念のため */
    line-height: 1.3;
    /* 日付と曜日の2行表示のための行間調整 */
}

/* 土曜日・日曜日の日付ヘッダースタイル */
#availability_table thead th.saturday-header {
    background-color: #e6f7ff;
    /* 土曜日の背景色 (薄い青) */
    color: #007bff;
    /* 土曜日の文字色 */
}

#availability_table thead th.sunday-header {
    background-color: #ffe6e6;
    /* 日曜日の背景色 (薄い赤) */
    color: #dc3545;
    /* 日曜日の文字色 */
}

#availability_table thead th:first-child {
    /* 左上の「部屋タイプ」セル */
    left: 0;
    padding: 10px 15px;
    width: 120px;
    /* スマホ向けに調整 */
    min-width: 100px;
    /* スマホ向けに調整 */
    /* 同上 */
    /* Specific padding for this header cell */
    background-color: #f1f3f5;
    /* Match date header background for consistency */
    /* 左端に固定 */
    z-index: 3;
    /* 最前面に表示 */
}

#availability_table tbody th {
    /* 部屋タイプ名の列ヘッダー */
    position: -webkit-sticky;
    /* Safari対応 */
    position: sticky;
    left: 0;
    z-index: 1;
    /* 他のセルより手前に表示 (日付ヘッダーよりは下) */
    background-color: #f8f9fa;
    text-align: left;
    /* 部屋タイプ名は左寄せ */
    font-weight: 600;
    /* 少し太くして視認性アップ */
    width: 120px;
    /* スマホ向けに調整 */
    min-width: 100px;
    /* スマホ向けに調整 */
    font-size: 0.85em;
    /* スマホでは少しフォントを小さく */
    /* 最小幅も上記widthと合わせる */
    /* max-width の制限は解除 */
    padding: 10px 5px;
    /* パディングを少し減らして中央揃えしやすく */
    white-space: nowrap;
    /* 改行を禁止 */
    overflow: hidden;
    /* はみ出した内容を隠す */
    text-overflow: ellipsis;
    /* はみ出した部分を...で表示 */
    /* Specific padding for room type header cells */
    /* 部屋タイプヘッダーの右側の境界線を明確にする */
    border-right: 1px solid #c0c0c0;
    text-align: center;
    /* 部屋タイプ名を中央揃え */
    /* 少し濃いめのグレーで区切りを明確に */
}

/* 緑: 〇 */
#availability_table td.available {
    cursor: pointer;
    color: #28a745;
    font-weight: bold;
    font-size: 1.4em;
    /* 「〇」の文字を少し大きく */
    transition: background-color 0.2s ease, transform 0.1s ease;
    /* display: flex や height: 100% は削除し、table-cell の標準動作に依存 */
}

#availability_table td.available:hover {
    background-color: #e6f7ff;
    transform: scale(1.05);
    /* 少し拡大するフィードバック */
}

#availability_table td.available:active {
    background-color: #cceeff;
    /* クリック/タップ時の背景色 */
    transform: scale(0.98);
    /* 少し縮小するフィードバック */
}

/* 赤: × */
#availability_table td.unavailable {
    color: #dc3545;
    font-weight: bold;
    font-size: 1.4em;
}

/* グレー: - */
#availability_table td.closed {
    color: #6c757d;
    background-color: #e9ecef;
    cursor: not-allowed;
    font-weight: bold;
    font-size: 1.2em;
}

/* スマートフォン向けのスタイル調整 (availability_calendar.html) */
@media (max-width: 768px) {
    .calendar-page-container {
        padding-left: 5px;
        padding-right: 5px;
    }

    .calendar-controls h3 {
        font-size: 1.3em;
        margin: 0 10px;
    }

    .month-nav-button {
        padding: 6px 10px;
        font-size: 0.85em;
    }

    #availability_table th,
    #availability_table td {
        height: 45px;
        /* セルの高さを少し詰める */
        font-size: 0.8em;
        /* 全体的にフォントを小さく */
    }

    #availability_table thead th {
        /* 日付ヘッダー */
        min-width: 38px;
        /* 日付ヘッダーの最小幅をさらに詰める */
        padding: 8px 1px;
        /* パディングも詰める */
        line-height: 1.2;
    }

    #availability_table thead th:first-child {
        /* 左上セル */
        width: 75px;
        /* 部屋タイプヘッダーと合わせる */
        min-width: 65px;
        padding: 8px 5px;
        /* パディングも詰める */
        font-size: 0.8em;
    }

    #availability_table tbody th {
        /* 部屋タイプ名ヘッダー */
        width: 75px;
        min-width: 65px;
        padding: 8px 5px;
        /* パディングも詰める */
        font-size: 0.75em;
        /* 部屋タイプ名はさらに少し小さく */
    }

    #availability_table td.available,
    #availability_table td.unavailable {
        font-size: 1.2em;
        /* 〇×記号のサイズ調整 */
    }

    #availability_table td.closed {
        font-size: 1em;
    }
}

@media (max-width: 480px) {
    .calendar-controls h3 {
        font-size: 1.1em;
        margin: 0 5px;
    }

    #availability_table thead th {
        /* 日付ヘッダー */
        min-width: 32px;
        /* さらに詰める (5日分表示を目指す) */
        padding: 6px 1px;
        /* パディングも極力詰める */
    }

    #availability_table thead th:first-child,
    /* 左上セル */
    #availability_table tbody th {
        /* 部屋タイプ名ヘッダー */
        width: 65px;
        min-width: 55px;
        padding: 6px 3px;
        /* パディングも詰める */
        font-size: 0.7em;
    }
}

/* プログレスバー */
.progress-bar-container {
    width: 100%;
    max-width: 600px;
    /* コンテンツ幅に合わせて調整 */
    /* ロゴとプログレスバーの間の余白を調整 */
    margin: 0 auto 20px auto;
    /* 上はbodyのpaddingがあるので0、下はコンテンツとの間隔 */
    padding: 0 10px;
}

.custom-progress-bar {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: space-between;
    position: relative;
}

.custom-progress-bar::before {
    /* ステップ間の背景線 */
    content: "";
    position: absolute;
    top: 15px;
    /* マーカーの直径が30pxなので、その半分程度を左右から控える */
    left: 15px;
    right: 15px;
    height: 4px;
    background-color: #e0e0e0;
    z-index: 1;
    /* 背景線 */
}

.custom-progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    z-index: 2;
    /* 背景線より手前 */
    width: auto;
    /* ラベルの長さに応じて幅を自動調整 */
    padding: 0 10px;
    /* ステップ間の最小間隔を確保 */
}

.custom-progress-step-marker {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #e0e0e0;
    /* 未完了マーカー背景 */
    color: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    border: 2px solid #e0e0e0;
    /* 未完了マーカー枠線 */
    margin-bottom: 8px;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.custom-progress-step-label {
    font-size: 0.9em;
    color: #6c757d;
    /* 未完了ラベル文字色 */
    white-space: nowrap;
    /* ラベルが改行しないように */
}

/* 完了したステップ */
.custom-progress-step.completed .custom-progress-step-marker {
    background-color: #007bff;
    /* 完了マーカー背景 */
    border-color: #007bff;
}

.custom-progress-step.completed .custom-progress-step-label {
    color: #007bff;
    /* 完了ラベル文字色 */
}

/* 完了したステップから次のステップへの線 */
/* CSSのみでの正確な描画が難しいため、この線の表示は一旦削除します。
   マーカーの色変更で進捗を示します。 */

/* 現在アクティブなステップ */
.custom-progress-step.active .custom-progress-step-marker {
    background-color: #28a745;
    /* アクティブマーカー背景 */
    border-color: #28a745;
}

.custom-progress-step.active .custom-progress-step-label {
    color: #28a745;
    /* アクティブラベル文字色 */
    font-weight: bold;
}

/* 予約確認画面 (confirm.html) 用スタイル */
.confirmation-group {
    display: flex;
    flex-wrap: wrap;
    /* ラベルと値が長い場合に折り返す */
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
    /* 項目間の薄い区切り線 */
    margin-bottom: 0;
    /* form-group のマージンは不要なのでリセット */
}

.confirmation-group:last-child {
    border-bottom: none;
}

.confirmation-label {
    font-weight: bold;
    color: #495057;
    width: 220px;
    /* ラベルの幅を調整 (例: 220px) */
    /* ラベルの幅を固定 */
    padding-right: 15px;
    /* ラベルと値の間のスペース */
    flex-shrink: 0;
    /* ラベルが縮まないように */
}

.confirmation-value {
    color: #212529;
    flex-grow: 1;
    /* 値が残りのスペースを埋めるように */
}

.confirmation-value.price-amount,
.confirmation-group .price-amount {
    /* 内訳の金額も右寄せにするためにセレクタを強化 */
    text-align: right;
    /* 金額は右寄せ */
}

.confirmation-meal-details ul {
    list-style: none;
    padding-left: 0;
    margin-top: 5px;
}

.confirmation-meal-details li {
    margin-bottom: 3px;
    font-size: 0.95em;
}

.price-details-section {
    margin-top: 20px;
    margin-bottom: 10px;
    /* お支払い総計との間隔 */
    padding: 15px;
    background-color: #f8f9fa;
    /* 少し背景色を変える */
    border-radius: 4px;
}

.price-details-title {
    font-size: 1.1em;
    font-weight: bold;
    color: #333;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e0e0e0;
    text-align: left;
    /* 左寄せ */
}

.form-section-title {
    font-size: 1.4em;
    color: #333;
    margin-top: 0;
    /* カードのパディング内で上端に配置 */
    padding-top: 15px;
    /* 上線の上のスペース */
    margin-bottom: 20px;
    /* padding-bottom: 10px; */
    /* 下線削除のため不要に */
    /* border-bottom: 1px solid #ddd; */
    /* 下線を削除 */
    border-top: 1px solid #e0e0e0;
    /* 上線を追加 */
}

.total-payment-group .confirmation-label {
    /* 「お支払い総計」のラベル */
    color: #007bff;
    /* 合計金額のラベルを強調 */
    font-size: 1.1em;
    /* 少し大きく */
}

.price-value {
    /* 「お支払い総計」の値 */
    font-size: 1.3em;
    font-weight: bold;
    color: #dc3545;
    /* 合計金額を赤で強調 */
    text-align: right;
    /* 金額を右詰めに */
}

.confirmation-actions {
    display: flex;
    gap: 15px;
    /* ボタン間のスペース */
    margin-top: 30px;
    /* 上のセクションとのマージン */
}

.form-actions {
    display: flex;
    flex-direction: column;
    /* ボタンを縦に並べる */
    gap: 10px;
    /* ボタン間のスペースを少し詰める */
    margin-top: 30px;
    /* justify-content: flex-end; */
    /* 縦並びなので不要 */
}

/* .form-actions button { flex: 1; } */
/* 縦並びなのでflex:1は不要、width:100%が基本 */

/* プライマリボタン (予約確認へ進む など) */
.form-actions button[type="submit"] {
    /* スタイルは既存の button, input[type="submit"] のものが適用される */
}

/* セカンダリボタン (戻る など) */
.secondary-button {
    background-color: #f8f9fa;
    /* 背景を白に近いグレーに */
    color: #495057;
    /* テキスト色を濃いグレーに */
    border: 1px solid #ced4da;
    /* 枠線を追加 */
}

.secondary-button:hover {
    background-color: #e2e6ea;
    /* ホバー時の背景色 */
    border-color: #dae0e5;
}

.confirmation-actions button {
    flex: 1;
    /* ボタンがスペースを分け合う */
}

.subtotal-group .confirmation-label,
.tax-group .confirmation-label {
    font-weight: 500;
    /* 通常の太さより少し強調 */
}

.subtotal-group .confirmation-value,
.tax-group .confirmation-value {
    font-weight: 500;
}

.price-breakdown-item {
    display: flex;
    justify-content: space-between;
    /* ラベルと金額を両端に */
    padding: 3px 0;
}

.price-breakdown-item span:last-child {
    /* 内訳の金額部分を右詰めに */
    text-align: right;
    margin-left: auto;
    /* 左側のラベルとの間にスペースを最大化 */
}

/* booking_details.html の料金サマリーエリア */
.price-summary-section {
    margin-top: 25px;
    /* 上の要素とのマージンを増やす */
    padding-top: 20px;
    /* パディングを増やす */
    border-top: 1px solid #e0e0e0;
    /* 区切り線を少し濃く */
}

.price-breakdown-container {
    /* 内訳表示コンテナのスタイル */
    margin-bottom: 15px;
    /* 合計金額表示との間隔 */
    padding: 15px;
    border: 1px solid #eee;
    border-radius: 4px;
    background-color: #f9f9f9;
}

.total-summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.total-summary-label {
    font-weight: bold;
    font-size: 1.1em;
    color: #333;
}

.total-summary-value {
    font-size: 1.3em;
    font-weight: bold;
    color: #dc3545;
    /* 強調色 */
    text-align: right;
    /* 金額を右寄せに */
    flex-grow: 1;
    /* ラベルとの間でスペースを埋める */
    margin-right: 10px;
}

.total-summary-actions {
    text-align: right;
    /* ボタンを右寄せにする場合 */
}

/* 空室カレンダーの案内メッセージ (availability_calendar.html) */
.user-guidance {
    background-color: #e6f7ff;
    /* 薄い水色背景 */
    border: 1px solid #b3e0ff;
    /* 少し濃い水色の枠線 */
    color: #0056b3;
    /* やや濃い青色の文字 */
    padding: 15px;
    margin-bottom: 20px;
    /* カレンダーコントロールとの間隔 */
    border-radius: 5px;
    text-align: center;
    font-size: 1.05em;
}

.user-guidance p {
    margin: 0;
    /* pタグのデフォルトマージンをリセット */
}

/* booking_details.html - 部屋詳細情報セクション */
.room-details-info {
    background-color: #f9f9f9;
    /* やや薄い背景色 */
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    padding: 15px 20px;
    margin-top: 15px;
    /* 上の要素との間隔 */
}

.room-details-info-title {
    font-size: 1.2em;
    /* booking.html の h3 より少し小さく */
    color: #333;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #ddd;
    text-align: left;
    /* 左寄せ */
}

.room-details-info p {
    margin-bottom: 8px;
    font-size: 0.95em;
    line-height: 1.5;
}

.amenities-list {
    list-style: disc;
    /* 点のリストマーカー */
    margin-left: 20px;
    /* 左側のインデント */
    padding-left: 5px;
}

.room-description-text {
    margin-top: 10px;
    font-style: italic;
    color: #555;
}

/* 予約関連のユーティリティリンク用スタイル */
.booking-utility-links {
    text-align: center;
    margin-top: 50px;
}

.booking-utility-links .booking-modify-link {
    color: #0056b3;
    text-decoration: underline;
    font-weight: 500;
    font-size: 1.1em;
}

.booking-utility-links .booking-modify-link:hover {
    color: #007bff;
}

.modern-room-modal .modal-room-image-container {
    width: 100%;
    max-width: 480px;
    margin: 0 auto 1.5rem auto;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.10);
    position: relative;
}

.modern-room-modal .modal-room-image {
    width: 100%;
    height: 260px;
    object-fit: cover;
    border-radius: 16px;
    display: block;
}

.modern-room-modal .carousel-inner {
    border-radius: 16px;
}

.modern-room-modal .carousel-control-prev,
.modern-room-modal .carousel-control-next {
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.18));
}

.modern-room-modal .carousel-control-prev-icon,
.modern-room-modal .carousel-control-next-icon {
    background-size: 80% 80%;
}

.modal-room-title {
    /* style.css の h3 スタイルを参考に調整 */
    font-size: 1.6em;
    color: #2c3e50;
    margin-bottom: 20px;
    text-align: left;
    /* モーダル内タイトルは左寄せ */
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 10px;
}

.modal-room-details p,
.modal-room-details ul {
    margin-bottom: 10px;
}

.modal-divider {
    border: 0;
    border-top: 1px solid #eee;
    margin: 20px 0;
    /* 上下のマージン */
}

.modal-common-info-title {
    font-size: 1.2em;
    color: #333;
    margin-top: 15px;
    /* 上の区切り線との間隔 */
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid #e0e0e0;
    text-align: left;
}

.common-info-section p strong {
    display: block;
    /* "お食事:" などをブロック要素にして改行 */
    margin-bottom: 3px;
}

.common-info-details {
    font-size: 0.9em;
    line-height: 1.5;
    margin-bottom: 15px;
    /* 各共通情報セクション間のマージン */
    padding-left: 10px;
    /* 少しインデント */
}

/* availability_calendar.html の部屋タイプクリック強調用スタイル */
.clickable-room-type {
    cursor: pointer;
}

.clickable-room-type:hover {
    text-decoration: underline;
    background-color: #e9f5ff;
    /* Light blue hover */
}

.clickable-room-type:active {
    background-color: #d0eaff;
    /* Slightly darker blue for active/tap */
}

.clickable-room-type .details-arrow {
    color: #007bff;
    /* Blue, similar to a link */
    margin-left: 5px;
    font-weight: normal;
}

/* 予約検索ページ (search_booking.html) 用スタイル */
.search-form {
    max-width: 500px;
    margin: 0 auto 30px auto;
    /* 中央寄せ */
    background-color: #f9f9f9;
    padding: 20px 25px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
}

.search-form .form-actions button {
    width: 100%;
}

.booking-result {
    border: 1px solid #e0e0e0;
    padding: 25px;
    border-radius: 6px;
    background-color: #fdfdff;
}


.faq-item {
  padding: 16px 0;
  border-bottom: 1px solid #ddd;
  transition: background-color 0.2s ease;
}

.faq-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
}

.faq-question {
  font-weight: 700;
  font-size: 1.15rem;
  color: #004085;
  margin-bottom: 8px;
  user-select: text;
  display: flex;
  align-items: center;
}

.faq-question::before {
  content: "Q:";
  font-weight: 700;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 1.1rem;
  color: #1a73e8;
  margin-right: 8px;
  user-select: none;
  vertical-align: middle;
}

.faq-answer {
  font-size: 1rem;
  color: #333;
  white-space: pre-wrap;
  line-height: 1.6;
  margin-left: 26px;
  display: flex;
  align-items: flex-start;
}

.faq-answer::before {
  content: "A:";
  font-weight: 700;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 1.1rem;
  color: #34a853;
  margin-right: 8px;
  user-select: none;
  vertical-align: middle;
}

.faq-item:hover {
  background-color: #f0f8ff;
}

@media (max-width: 480px) {
  .faq-question {
    font-size: 1rem;
  }
  .faq-question::before {
    font-size: 1rem;
  }
  .faq-answer {
    font-size: 0.95rem;
    margin-left: 20px;
  }
  .faq-answer::before {
    font-size: 1rem;
  }
}

