/* 오프라인 상태 표시 */
.offline-status {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: #ff4444;
    color: white;
    text-align: center;
    padding: 0.5em;
    z-index: 9999;
    display: none;
}

body.offline .offline-status {
    display: block;
}

body.offline a[data-external] {
    opacity: 0.5;
    pointer-events: none;
}

/* 링크 스타일 */
a[data-mapped]::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #4CAF50;
    border-radius: 50%;
    margin-right: 5px;
}

a[data-dynamic]::before {
    background: #2196F3;
}

a[data-external]::before {
    background: #FFC107;
}

/* 모달 스타일 */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
}

.modal-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* 모달 컨테이너 */
.modal-container {
    background: #f8f9fa;
    width: 90%;
    max-width: 440px;
    border-radius: 12px;
    position: relative;
    padding: clamp(16px, 3vw, 24px);
    margin: auto;
    max-height: min(90vh, 600px);
    overflow: hidden;
}

/* 닫기 버튼 스타일 */
.modal-close {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 28px;
    font-weight: bold;
    color: #666;
    cursor: pointer;
    z-index: 1001;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f1f1;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.modal-close:hover {
    color: #333;
    background: #e0e0e0;
}

/* 로고 스타일 */
.authentication-logo {
    width: 100%;
    height: auto;
    max-width: clamp(100px, 25vw, 120px);
    margin: 0 auto 8px;
    display: block;
    object-fit: contain;
}

/* 타이틀과 설명 스타일 */
.authentication-title {
    font-size: clamp(18px, 4vw, 22px);
    font-weight: 600;
    color: #1a1a1a;
    text-align: center;
    margin-bottom: 2px;
}

.authentication-details {
    font-size: clamp(12px, 3vw, 14px);
    color: #666;
    text-align: center;
    margin-bottom: clamp(12px, 3vw, 16px);
}

/* 폼 필드 스타일 */
.booking-field-wrap {
    margin-bottom: clamp(6px, 2vw, 8px);
}

.contact-field {
    width: 100%;
    height: clamp(36px, 8vw, 40px);
    padding: 0 clamp(12px, 3vw, 16px);
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: clamp(14px, 3vw, 16px);
    margin-bottom: clamp(6px, 2vw, 8px);
}

.contact-field:focus {
    border-color: #ff5c35;
    outline: none;
}

.contact-field::placeholder {
    color: #999;
}

.contact-label {
    font-size: clamp(12px, 3vw, 14px);
    margin-bottom: 4px;
    display: block;
}

/* 버튼과 링크 스타일 */
.form-button {
    width: 100%;
    height: clamp(36px, 8vw, 40px);
    font-size: clamp(14px, 3vw, 16px);
    border-radius: clamp(20px, 5vw, 24px);
    background: #ff5c35;
    color: white;
    border: none;
    cursor: pointer;
    opacity: 1;
}

.form-button:hover {
    background: #ff4419;
}

.sign-in-link {
    color: #ff5c35;
    text-decoration: none;
    font-size: clamp(12px, 3vw, 14px);
    font-weight: 500;
    opacity: 1;
}

.sign-in-link:hover {
    text-decoration: underline;
}

.terms-wrapper {
    text-align: right;
    margin: -2px 0 clamp(8px, 2vw, 12px);
}

.alternative-details {
    text-align: center;
    margin-top: clamp(8px, 2vw, 12px);
    color: #666;
    font-size: clamp(12px, 3vw, 14px);
    opacity: 1;
}

.alternative-link {
    color: #ff5c35;
    text-decoration: none;
    font-weight: 500;
    opacity: 1;
}

.alternative-link:hover {
    text-decoration: underline;
    opacity: 1;
}

/* 폼 상태 메시지 */
.w-form-done, .w-form-fail {
    display: none;
    padding: 20px;
    text-align: center;
    border-radius: 8px;
    margin-top: 20px;
    opacity: 1;
}

.w-form-done {
    background: #e8f5e9;
}

.w-form-fail {
    background: #ffebee;
}

/* 모바일 대응 */
@media screen and (max-width: 479px) {
    .modal-container {
        padding: 16px;
        margin: 12px;
        width: calc(100% - 24px);
        max-height: 85vh;
    }
    
    .authentication-title {
        font-size: 20px;
    }
    
    .authentication-details {
        font-size: 13px;
    }

    .modal-close {
        right: 12px;
        top: 8px;
        width: 24px;
        height: 24px;
        font-size: 24px;
    }
}

/* 관리자 아이콘 스타일 */
.admin-icon-link {
    display: flex;
    align-items: center;
    padding: 5px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.admin-icon-link:hover {
    transform: scale(1.1);
    opacity: 0.8;
}

/* 로딩 스피너 */
.spinner {
    display: none;
}

/* 메시지 스타일 */
#loginMessage {
    display: none;
    margin: 10px 0;
    padding: 10px;
    border-radius: 4px;
    text-align: center;
}

/* 성공 메시지 */
#loginMessage.success {
    background-color: #4CAF50;
    color: white;
}

/* 에러 메시지 */
#loginMessage.error {
    background-color: #f44336;
    color: white;
}
