/* WawaCoin Auth Modal Styles */
.auth-modal {
    display: none;
    position: fixed !important;
    z-index: 99999 !important;
    left: 0 !important;
    top: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    animation: fadeIn 0.3s;
    overflow: hidden !important;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.auth-modal-content {
    background: linear-gradient(135deg, #1e1e1e 0%, #2a2a2a 100%);
    padding: 0;
    border: 1px solid rgba(247, 147, 26, 0.2);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    /* 정중앙 배치 - 절대 위치 지정 */
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    z-index: 100000 !important;
    margin: 0 !important;
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

.auth-modal-close {
    color: #888;
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    transition: color 0.3s;
}

.auth-modal-close:hover,
.auth-modal-close:focus {
    color: #f7931a;
}

/* 탭 스타일 */
.auth-tabs {
    display: flex;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0 20px;
    padding-top: 20px;
}

.auth-tab {
    flex: 1;
    padding: 15px;
    background: transparent;
    border: none;
    color: #666;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
}

.auth-tab:hover {
    color: #888;
}

.auth-tab.active {
    color: #f7931a;
    border-bottom-color: #f7931a;
}

/* 탭 콘텐츠 */
.auth-tab-content {
    display: none;
    padding: 30px;
}

.auth-tab-content.active {
    display: block;
    animation: fadeIn 0.3s;
}

/* 헤더 */
.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-logo {
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
    background: linear-gradient(135deg, #f7931a 0%, #ff9900 100%);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: white;
    font-weight: bold;
}

.auth-header h2 {
    color: #fff;
    margin: 10px 0;
    font-size: 24px;
    font-weight: 600;
}

.auth-header p {
    color: #888;
    font-size: 14px;
    margin: 0;
}

/* 폼 스타일 */
.auth-form-group {
    margin-bottom: 20px;
}

.auth-form-group label {
    display: block;
    color: #f7931a;
    font-size: 14px;
    margin-bottom: 8px;
    font-weight: 500;
}

.auth-form-group input {
    width: 100%;
    padding: 12px 15px;
    background: #252525;
    border: 1px solid #3a3a3a;
    border-radius: 8px;
    color: #fff;
    font-size: 14px;
    transition: all 0.3s;
    box-sizing: border-box;
}

.auth-form-group input:focus {
    outline: none;
    border-color: #f7931a;
    background: #2a2a2a;
    box-shadow: 0 0 0 3px rgba(247, 147, 26, 0.1);
}

.auth-form-group input::placeholder {
    color: #666;
}

.auth-form-group small {
    display: block;
    color: #666;
    font-size: 12px;
    margin-top: 5px;
}

/* 필수/선택 표시 */
.required {
    color: #ff4444;
    margin-left: 3px;
}

.optional {
    color: #666;
    font-size: 12px;
    font-weight: normal;
    margin-left: 5px;
}

/* 폼 행 */
.auth-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

/* 폼 구분선 */
.auth-form-divider {
    margin: 30px 0 20px;
    text-align: center;
    position: relative;
}

.auth-form-divider:before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.auth-form-divider span {
    background: linear-gradient(135deg, #1e1e1e 0%, #2a2a2a 100%);
    padding: 0 20px;
    color: #666;
    font-size: 13px;
    position: relative;
}

/* 폼 옵션 */
.auth-form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 20px 0;
    gap: 10px;
}

.auth-forgot-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.auth-remember {
    display: flex;
    align-items: center;
    color: #888;
    font-size: 14px;
    cursor: pointer;
}

.auth-remember input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
    cursor: pointer;
}

.auth-forgot {
    color: #f7931a;
    text-decoration: none;
    font-size: 14px;
}

.auth-forgot:hover {
    text-decoration: underline;
}

.auth-forgot-separator {
    color: #666;
    margin: 0 5px;
    font-size: 14px;
}

/* 보조 버튼 (로그인하기 버튼) */
.auth-secondary-btn {
    width: 100%;
    padding: 12px;
    background: transparent;
    border: 1px solid #f7931a;
    color: #f7931a;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.auth-secondary-btn:hover {
    background: rgba(247, 147, 26, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(247, 147, 26, 0.2);
}

/* 제출 버튼 */
.auth-submit-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #f7931a 0%, #ff9900 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 20px;
}

.auth-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(247, 147, 26, 0.3);
}

.auth-submit-btn:active {
    transform: translateY(0);
}

.auth-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* 메시지 */
.auth-error {
    background: rgba(255, 68, 68, 0.1);
    border: 1px solid rgba(255, 68, 68, 0.3);
    color: #ff4444;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 20px;
    font-size: 14px;
    display: none;
}

.auth-success {
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: #4caf50;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 20px;
    font-size: 14px;
    display: none;
}

/* 반응형 */
@media (max-width: 768px) {
    .auth-modal-content {
        width: 95%;
        max-width: 400px;
        max-height: 85vh;
    }

    .auth-form-row {
        grid-template-columns: 1fr;
    }

    .auth-tab-content {
        padding: 20px;
    }

    .auth-tabs {
        padding-top: 15px;
    }

    .auth-modal-close {
        right: 15px;
        top: 10px;
    }
}