/* 상담 예약 페이지 전용 스타일 */

section:has(.formmail-container) {
    background: linear-gradient(180deg, #DEBC80 0%, #8C7351 100%);
    position: relative;
}

.formmail-container {
    min-height: 100%;
    padding: 60px 0;
    position: relative;
    z-index: 1;
}

.formmail-container::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    background-image: url('/site1/res/pub/front/images/reservation/logoBack.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.15;
    z-index: 0;
    pointer-events: none;
}

.formmail-container .page-title-wrapper {
    text-align: center;
    margin-bottom: 20px;
}

.formmail-container .page-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.formmail-container .page-subtitle-wrapper {
    text-align: center;
    margin-bottom: 20px;
}

.formmail-container .page-subtitle {
    font-size: 1.3rem;
    color: #5a4a3a;
    margin-bottom: 0;
    font-weight: 500;
}

.formmail-container .reservation-form {
    background: transparent;
    border-radius: 20px;
    padding: 40px;
    box-shadow: none;
    max-width: 600px;
    margin: 0 auto;
    border: none;
}

.form-fields {
    margin-bottom: 40px;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 8px;
    display: block;
    font-size: 14px;
}

.form-control {
    border: 2px solid #e9ecef;
    border-radius: 15px;
    padding: 15px 18px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.9);
}

.form-control:focus {
    border-color: #DEBC80;
    box-shadow: 0 0 0 0.2rem rgba(222, 188, 128, 0.25);
    background: white;
}

.form-control::placeholder {
    color: #adb5bd;
    font-size: 14px;
}

.zipcode-group {
    display: flex;
    gap: 12px;
}

.zipcode-btn {
    background: linear-gradient(135deg, #4A90E2, #357ABD);
    color: white;
    border: none;
    border-radius: 15px;
    padding: 15px 24px;
    font-weight: 600;
    white-space: nowrap;
    transition: all 0.3s ease;
    font-size: 14px;
}

.zipcode-btn:hover {
    background: linear-gradient(135deg, #357ABD, #2E6BA8);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(74, 144, 226, 0.4);
}

.consent-section {
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    border: 1px solid rgba(222, 188, 128, 0.3);
    backdrop-filter: blur(5px);
}

.consent-item {
    margin-bottom: 10px;
}

.consent-item:last-child {
    margin-bottom: 0;
}

/* 전체 동의 스타일 */
.consent-item.consent-all {
    background: transparent;
    border: none;
    border-bottom: 2px solid #8C7351;
    border-radius: 0;
    padding: 8px 0;
    margin-bottom: 8px; 
}

.consent-item.consent-all .checkbox-label {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
}

.consent-item.consent-all .checkbox-text {
    color: #8C7351;
    font-weight: 600;
}

.consent-item.consent-all .checkbox-icon {
    width: 24px;
    height: 24px;
    border: 2px solid #DEBC80;
    border-radius: 8px;
    margin-right: 12px;
    background: white;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.2s ease;
}

.consent-item.consent-all .checkbox-icon:hover {
    border-color: #D4A574;
    background: rgba(222, 188, 128, 0.1);
}

.consent-item.consent-all input[type="checkbox"]:checked + .checkbox-label .checkbox-icon {
    background: #DEBC80;
    border-color: #DEBC80;
}

.consent-item.consent-all input[type="checkbox"]:checked + .checkbox-label .checkbox-icon::after {
    content: '✓';
    color: white;
    font-size: 14px;
    font-weight: bold;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* 개별 동의 행 스타일 */
.consent-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    padding: 9px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(222, 188, 128, 0.15);
}

.custom-checkbox {
    display: flex;
    align-items: center;
    position: relative;
    flex: 1;
}

.custom-checkbox input[type="checkbox"] {
    display: none;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 15px;
    color: #2c3e50;
    font-weight: 500;
    user-select: none;
    line-height: 1.5;
    width: 100%;
}

/* 개별 동의 체크박스 스타일 - 전체 동의와 동일하게 수정 */
.checkbox-icon {
    width: 24px;
    height: 24px;
    border: 2px solid #DEBC80;
    border-radius: 8px;
    margin-right: 12px;
    background: white;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.2s ease;
}

.checkbox-icon:hover {
    border-color: #D4A574;
    background: rgba(222, 188, 128, 0.1);
}

/* 체크된 상태 스타일 - 전체 동의와 동일하게 수정 */
.checkbox-icon.checked {
    background: #DEBC80;
    border-color: #DEBC80;
}

.checkbox-icon.checked::after {
    content: '✓';
    color: white;
    font-size: 14px;
    font-weight: bold;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* 약관보기 버튼 스타일 */
.consent-detail-btn {
    background: linear-gradient(135deg, #8C7351, #6B5A42);
    color: white;
    border: none;
    border-radius: 25px;
    padding: 9px 17px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    min-width: 75px;
    box-shadow: 0 3px 10px rgba(140, 115, 81, 0.3);
    flex-shrink: 0;
}

.consent-detail-btn:hover {
    background: linear-gradient(135deg, #6B5A42, #5A4935);
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(140, 115, 81, 0.4);
}

.consent-detail-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(140, 115, 81, 0.3);
}

/* 개별 동의 체크박스가 체크되었을 때 전체 동의와 동일한 색상 적용 */
.custom-checkbox input[type="checkbox"]:checked + .checkbox-label .checkbox-icon {
    background: #DEBC80;
    border-color: #DEBC80;
}

.custom-checkbox input[type="checkbox"]:checked + .checkbox-label .checkbox-icon::after {
    content: '✓';
    color: white;
    font-size: 14px;
    font-weight: bold;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* 개인정보처리방침 모달 스타일 */
.privacy-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease-out;
}

.privacy-modal {
    background: white;
    border-radius: 25px;
    max-width: 900px;
    width: 100%;
    max-height: 85vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
    transform-origin: center;
}

.privacy-modal-header {
    padding: 20px 30px;
    border-bottom: 2px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #DEBC80, #D4A574);
    position: relative;
    border-radius: 25px 25px 0 0;
}

.privacy-modal-title {
    font-size: 18px;
    font-weight: 700;
    color: white;
    margin: 0;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

.privacy-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: white;
    cursor: pointer;
    padding: 0;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    font-weight: bold;
}

.privacy-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.privacy-modal-body {
    padding: 0;
    max-height: hidden;
    height: 500px;
    overflow: hidden;
}

.privacy-modal-body iframe {
    width: 100%;
    height: cal(100% + 120px);
    border: none;
    margin-top: -10px;
}
/* 모달 애니메이션 */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(-50px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* 모달이 열려있을 때 body 스크롤 방지 */
.modal-open {
    overflow: hidden !important;
}

.submit-section {
    position: relative;
    width: 100%;
}

.submit-btn {
    width: 100%;
    background: linear-gradient(135deg, #4A90E2, #357ABD);
    color: white;
    border: none;
    border-radius: 20px;
    padding: 18px;
    font-size: 18px;
    font-weight: 700;
    transition: all 0.3s ease;
    text-transform: none;
    letter-spacing: 0.5px;
}

.submit-btn:hover {
    background: linear-gradient(135deg, #357ABD, #2E6BA8);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(74, 144, 226, 0.4);
}

.mascot-inline {
    position: absolute;
    right: -140px;
    top: 50%;
    transform: translateY(-50%);
    width: clamp(80px, 12vw, 120px);
    height: auto;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.2));
    transition: all 0.3s ease;
}

.mascot {
    position: fixed;
    bottom: 120px;
    right: 30px;
    width: 120px;
    height: auto;
    z-index: 1000;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.2));
}

textarea {
    resize: none;
}
textarea.form-control {
    resize: none !important;
    min-height: 120px;
}

textarea.form-control:focus {
    min-height: 140px;
    transition: min-height 0.3s ease;
}

footer {
    position: relative;
    z-index: 10;
    background: white;
}

/* 반응형 디자인 */
@media (max-width: 768px) {
    .page-title {
        font-size: 2.2rem;
    }

    .page-subtitle {
        font-size: 1.1rem;
    }

    .reservation-form {
        padding: 25px;
        margin: 0 15px;
        border-radius: 15px;
    }

    .zipcode-group {
        flex-direction: column;
    }

    .zipcode-btn {
        width: 100%;
    }

    .mascot {
        display: none;
    }

    .mascot-inline {
        display: none;
    }

    .form-control {
        padding: 12px 15px;
        font-size: 15px;
    }

    .submit-btn {
        padding: 15px;
        font-size: 16px;
    }

    .consent-section {
        padding: 20px;
    }

    /* 태블릿에서 동의 행 레이아웃 유지 */
    .consent-row {
        padding: 10px;
        gap: 12px;
    }

    .checkbox-text {
        font-size: 14px;
        line-height: 1.4;
    }

    .consent-detail-btn {
        font-size: 11px;
        padding: 8px 14px;
        min-width: 68px;
        border-radius: 20px;
    }

    /* 태블릿 모달 */
    .privacy-modal-overlay {
        padding: 12px;
        align-items: flex-start;
    }
    
    .privacy-modal {
        margin-top: 20px;
        max-height: 90vh;
        border-radius: 20px;
    }
    
    .privacy-modal-header {
        padding: 16px 20px;
        border-radius: 20px 20px 0 0;
    }
    
    .privacy-modal-title {
        font-size: 16px;
    }
    
    .privacy-modal-close {
        width: 32px;
        height: 32px;
        font-size: 24px;
    }
    
    .privacy-modal-body iframe {
        height: 450px;
    }
}

@media (max-width: 480px) {
    .page-title {
        font-size: 1.8rem;
    }

    .reservation-form {
        padding: 20px;
    }

    .consent-section {
        padding: 18px;
    }

    .mascot {
        display: none;
    }

    .mascot-inline {
        display: none;
    }

    .submit-section {
        text-align: center;
    }

    .consent-item.consent-all {
        background: transparent;
        border: none;
        border-bottom: 2px solid #8C7351;
        border-radius: 0;
        padding: 8px 0;
        margin-bottom: 6px;
    }
    .consent-item.consent-all .checkbox-text {
        font-size: 1.1rem; 
        font-weight: 700;
        line-height: 1.4;
    }


    .consent-item {
        margin-bottom: 8px;
    }

    /* 모바일에서도 같은 라인 유지 */
    .consent-row {
        flex-direction: row;
        align-items: center;
        gap: 8px;
        padding: 6px 8px;
        background: rgba(255, 255, 255, 0.08);
        border-radius: 8px;
        border: 1px solid rgba(222, 188, 128, 0.12);
    }

    .custom-checkbox {
        flex: 1;
        min-width: 0;
    }

    .checkbox-label {
        font-size: 10px;
        line-height: 1.4;
    }

    .checkbox-text {
        font-size: 10px;
        line-height: 1.4;
        word-break: keep-all;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .checkbox-icon {
        width: 20px;
        height: 20px;
        margin-right: 8px;
        border-radius: 6px;
    }

    .checkbox-icon.checked::after {
        font-size: 12px;
    }

    .consent-detail-btn {
        font-size: 10px;
        padding: 6px 10px;
        min-width: 50px;
        border-radius: 15px;
        background: linear-gradient(135deg, #8C7351, #6B5A42);
        box-shadow: 0 2px 6px rgba(140, 115, 81, 0.25);
        flex-shrink: 0;
    }

    .consent-detail-btn:hover {
        transform: translateY(-1px);
        box-shadow: 0 3px 8px rgba(140, 115, 81, 0.35);
    }

    /* 모바일 모달 최적화 */
    .privacy-modal-overlay {
        padding: 20px;
        align-items: center;
        justify-content: center;
    }
    
    .privacy-modal {
        margin: 0;
        border-radius: 15px;
        width: calc(100% - 40px);
        max-width: 400px;
        height: 400px;
        max-height: 400px;
        position: relative;
        bottom: auto;
        top: auto;
        left: auto;
        right: auto;
        animation: modalSlideIn 0.3s ease-out;
        display: flex;
        flex-direction: column;
    }
    
    .privacy-modal-header {
        padding: 12px 16px;
        background: linear-gradient(135deg, #DEBC80, #D4A574);
        border-radius: 15px 15px 0 0;
        position: relative;
        top: auto;
        z-index: 1;
        flex-shrink: 0;
    }
    
    .privacy-modal-title {
        font-size: 14px;
        font-weight: 700;
    }
    
    .privacy-modal-close {
        width: 28px;
        height: 28px;
        font-size: 18px;
        background: rgba(255, 255, 255, 0.15);
        border-radius: 50%;
    }
    
    .privacy-modal-body {
        flex: 1;
        overflow: hidden;
        border-radius: 0 0 15px 15px;
    }
    
    .privacy-modal-body iframe {
        width: 100%;
        height: 100%;
        border: none;
        border-radius: 0 0 15px 15px;
    }

    /* 모바일 모달 슬라이드업 애니메이션 */
    @keyframes modalSlideUp {
        from {
            opacity: 0;
            transform: translateY(100%);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}

/* 애니메이션 효과 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.reservation-form {
    animation: fadeInUp 0.8s ease-out;
}

.page-title {
    animation: fadeInUp 0.6s ease-out;
}

.page-subtitle {
    animation: fadeInUp 0.7s ease-out;
}

/* 로딩 상태 */
.submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none !important;
}

/* 포커스 상태 개선 */
.form-control:focus,
.zipcode-btn:focus,
.submit-btn:focus {
    outline: none;
}

/* 선택 드롭다운 스타일 */
select.form-control {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 12px center;
    background-repeat: no-repeat;
    background-size: 16px 12px;
    padding-right: 40px;
    appearance: none;
}

/* 텍스트 영역 스타일 */
textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

textarea.form-control:focus {
    min-height: 140px;
    transition: min-height 0.3s ease;
}

/* 터치 최적화 */
@media (max-width: 480px) {
    .consent-detail-btn {
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }

    .privacy-modal-close {
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }

    .checkbox-label {
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }

    /* iOS Safari 스크롤 부드럽게 */
    .privacy-modal-body {
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }
}