/**
 * Reserve System Pages Additional Styles
 * 元のテーマデザインとの統合用追加スタイル
 */

/* ==========================================================================
   フォームセクション
   ========================================================================== */
.p-reserveForm {
    padding: 60px 0;
    /* スクロール時のフッター問題を修正 */
    min-height: calc(100vh - 200px);
    position: relative;
}

.p-reserveForm__form {
    max-width: 1000px;
    margin: 0 auto;
}

.p-reserveForm__section {
    margin-bottom: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.p-reserveForm__sectionTitle {
    font-size: 24px;
    font-weight: 700;
    color: #d9d9d9 !important;
    text-align: center !important;
    margin-bottom: 40px;
}

/* ==========================================================================
   スタッフ選択
   ========================================================================== */
.p-staffSelect {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-width: 800px;
    margin: 0 auto;
}

.p-staffSelect__item {
    background: #f8f8f8;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    height: 180px;
}

.p-staffSelect__item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.p-staffSelect__content {
    display: flex;
    height: 100%;
}

.p-staffSelect__image {
    width: 120px;
    height: 100%;
    flex-shrink: 0;
    overflow: hidden;
}

.p-staffSelect__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.p-staffSelect__info {
    flex: 1;
    padding: 12px 15px;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
}

.p-staffSelect__name {
    font-size: 18px;
    font-weight: 700;
    color: #303c09;
    margin-bottom: 5px;
}

.p-staffSelect__meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px 10px;
    font-size: 15px;
    color: #666;
    margin-bottom: 8px;
    line-height: 1.2;
}

.p-staffSelect__meta span {
    display: flex;
    align-items: center;
    white-space: nowrap;
}

.p-staffSelect__info form {
    margin-top: 0;
    margin-bottom: 0;
}

.p-staffSelect__button,
.p-staffSelect__info button[type="submit"] {
    padding: 8px 20px !important;
    font-size: 14px !important;
    display: inline-block !important;
    width: auto !important;
    line-height: 1.4 !important;
    border-radius: 4px !important;
    margin: 0 !important;
}

/* ==========================================================================
   カスタマー情報フォーム
   ========================================================================== */
.customer-form-group {
    margin-bottom: 30px;
}

.customer-form-group label {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: #303c09;
    margin-bottom: 8px;
}

.customer-form-group .required {
    color: #e74c3c;
    margin-left: 4px;
}

.customer-form-group input,
.customer-form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.customer-form-group input:focus,
.customer-form-group textarea:focus {
    outline: none;
    border-color: #303c09;
}

.customer-form-group textarea {
    min-height: 120px;
    resize: vertical;
}

/* ==========================================================================
   ローディングモーダル
   ========================================================================== */
#loading-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9999;
}

.loading-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #fff;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ==========================================================================
   ナビゲーションボタン
   ========================================================================== */
.navigation-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid #e0e0e0;
}

.navigation-buttons .c-button {
    min-width: 150px;
}

/* ==========================================================================
   予約完了
   ========================================================================== */
.p-reserveComplete {
    padding: 60px 0;
}

.p-reserveComplete__message {
    text-align: center;
    padding: 60px 40px;
    background: #f8f8f8;
    border-radius: 8px;
}

.p-reserveComplete__icon {
    font-size: 60px;
    color: #303c09;
    margin-bottom: 20px;
}

.p-reserveComplete__title {
    font-size: 32px;
    font-weight: 700;
    color: #303c09;
    margin-bottom: 20px;
}

.p-reserveComplete__text {
    font-size: 16px;
    line-height: 1.8;
    color: #666;
    margin-bottom: 40px;
}

/* ==========================================================================
   選択内容の表示（日時・コース・スタッフ）
   ========================================================================== */
.p-reserveSelected {
    background: #f8f8f8;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.p-reserveSelected__content {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.p-reserveSelected__item {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
}

.p-reserveSelected__label {
    font-weight: 700;
}

/* ==========================================================================
   選択されたスタッフ表示（staff-first用）
   ========================================================================== */

.p-reserveSelected__title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
    text-align: center;
}

.p-reserveSelected__staff {
    display: flex;
    align-items: center;
    gap: 20px;
}

.p-reserveSelected__staffImage {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.p-reserveSelected__staffImage img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.p-reserveSelected__staffInfo h4 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
}

.p-reserveSelected__staffMeta {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px 16px;
    font-size: 12px;
}

.p-reserveSelected__staffMetaItem {
    display: flex;
    gap: 0.5em;
}

.p-reserveSelected__staffMetaLabel {
    color: #666;
}

.p-reserveSelected__staffMetaValue {
    font-weight: 700;
    color: #333;
}

/* ==========================================================================
   カレンダー
   ========================================================================== */
.p-calendar {
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.p-calendar__navigation {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    color: #d9d9d9 !important;
}

.p-calendar__currentMonth {
    font-size: 20px;
    font-weight: 700;
    color: #d9d9d9 !important;
}

.p-calendar__nav {
    background: #303c09;
    color: #fff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.p-calendar__nav:hover {
    background: #1f2806;
    transform: scale(1.1);
}

.p-calendar__wrapper {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.p-calendar__month-container {
    background: #f8f8f8;
    padding: 20px;
    border-radius: 8px;
}

.p-calendar__header {
    text-align: center;
    margin-bottom: 20px;
}

.p-calendar__month {
    font-size: 18px;
    font-weight: 700;
}

.p-calendar__weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    margin-bottom: 10px;
}

.p-calendar__weekday {
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: #666;
}

.p-calendar__days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.p-calendar__day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid #e0e0e0;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.p-calendar__day:hover:not(.is-disabled) {
    background: #fff5b8;
    color: #303c09 !important;
}

.p-calendar__day.is-selected {
    background: #303c09;
    color: #fff;
}

.p-calendar__day.is-disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.p-calendar__day.is-other-month {
    color: #ccc;
}

.p-calendar__day.is-weekend {
    color: #ff4444;
}

.p-calendar__day.is-weekend.is-disabled {
    color: #ffcccc;
}

/* ==========================================================================
   時間選択
   ========================================================================== */
.p-timeSelect {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
    max-width: 600px;
    margin: 0 auto;
}

.p-timeSelect__item {
    position: relative;
    cursor: pointer;
}

.p-timeSelect__item input {
    position: absolute;
    opacity: 0;
}

.p-timeSelect__label {
    display: block;
    padding: 15px;
    background: #f8f8f8;
    text-align: center;
    border: 2px solid transparent;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.p-timeSelect__item input:checked + .p-timeSelect__label {
    background: #303c09;
    color: #fff;
}

.p-timeSelect__item:hover .p-timeSelect__label {
    border-color: #303c09;
}

/* ==========================================================================
   コース選択
   ========================================================================== */
.p-courseSelect {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 600px;
    margin: 0 auto;
}

.p-courseSelect__item {
    position: relative;
    cursor: pointer;
}

.p-courseSelect__item input {
    position: absolute;
    opacity: 0;
}

.p-courseSelect__content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 30px;
    background: #f8f8f8;
    border: 2px solid transparent;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.p-courseSelect__item input:checked + .p-courseSelect__content {
    background: #303c09;
    color: #fff;
}

.p-courseSelect__item:hover .p-courseSelect__content {
    border-color: #303c09;
}

.p-courseSelect__time {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 10px;
}

.p-courseSelect__price {
    font-size: 18px;
}

.p-courseSelect__description {
    display: block;
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

/* ==========================================================================
   カスタマーフォーム
   ========================================================================== */
.p-customerForm__label {
    color: #d9d9d9 !important;
}

/* ==========================================================================
   送信ボタン
   ========================================================================== */
.p-reserveForm__submit {
    text-align: center;
    margin-top: 60px;
}

/* ==========================================================================
   レスポンシブ
   ========================================================================== */
@media (max-width: 768px) {
    .p-reserveForm {
        padding: 40px 0;
    }
    
    .p-reserveForm__section {
    }
    
    .p-reserveForm__sectionTitle {
        font-size: 20px;
        margin-bottom: 30px;
    }
    
    .p-staffSelect {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .p-staffSelect__item {
        height: 170px;
    }
    
    .p-staffSelect__image {
        width: 100px;
    }
    
    .p-staffSelect__info {
        padding: 12px;
    }
    
    .p-staffSelect__name {
        font-size: 16px;
    }
    
    .p-staffSelect__meta {
        font-size: 13px;
    }
    
    /* 選択内容表示 */
    .p-reserveSelected {
        padding: 12px 15px;
        margin-bottom: 20px;
    }
    
    .p-reserveSelected__title {
        font-size: 15px;
        margin-bottom: 10px;
    }
    
    .p-reserveSelected__content {
        flex-direction: column;
        gap: 8px;
    }
    
    .p-reserveSelected__item {
        font-size: 13px;
    }
    
    .navigation-buttons {
        flex-direction: column;
        gap: 20px;
    }
    
    .navigation-buttons .c-button {
        width: 100%;
    }
    
    .p-reserveComplete__message {
        padding: 40px 20px;
    }
    
    .p-reserveComplete__title {
        font-size: 24px;
    }
    
    /* カレンダー */
    .p-calendar__wrapper {
        grid-template-columns: 1fr;
    }
    
    .p-calendar__month-container {
        padding: 15px;
    }
    
    .p-calendar__navigation {
        gap: 15px;
    }
    
    .p-calendar__currentMonth {
        font-size: 18px;
    }
    
    /* 時間選択 */
    .p-timeSelect {
        grid-template-columns: repeat(3, 1fr);
    }
    
    /* コース選択 */
    .p-courseSelect {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .p-courseSelect__item {
    }
    
    .p-courseSelect__time {
        font-size: 14px;
    }
    
    .p-courseSelect__price {
        font-size: 16px;
    }
}